Daniel_Bowen's Q&A profile
Visual C# static method - Is there any workaround?
I think most know we cannot declare a static anything in an interface. However, let's say I have this: public sealed class MyClass { private MyClass(string someText) { m_someModifiedText = someText; } private readonly static m_someModifiedText; public static MyClass Create( string someText ) { string modifiedText= ModifyText(someText); return new MyClass(someText); } private string ModifyText(string someText) { string modifiedText = someText; //do something to modify text return modifiedText; } public static string UsefulText { return m_someModifiedText; } } Now, this "sample" is just to keep it simple, but PLEASE just consider the concept rather than what the ...Show All
Visual Basic Duplicate Items are not supported by the "Resources" parameter.
Hi, I have a VB.NET project with XHEO licensing(to license a product) and for that i am using <projetname>.PLSK file which was added to the my solution.When i tried create a new .plsk instead of existing one i got a error while building.The error is like this. "The item "obj\Release\<projectname>.plsk" was specified more than once in the "Resources" parameter. Duplicate items are not supported by the "Resources" parameter. I am sure there is only one plsk file and when i tried to build with previous .plsk file got the same error.Can any one tell me where is that resourse parameter are stored.How to delete that Thanks in advance. hi, try to load the .vbproj file into a text editor, and check for ...Show All
Visual Studio 2008 (Pre-release) Hosting xbap in a non-asp.net web site?
Since it's a client technology, it seems viable that a xbap could be host in a non-asp.net (such as FreeBSD host)web site only if I added the MIME types. Is this true How can I do this Thanks! Yup, creating that mime type on the server worked. However, I now get another error (and I can't seem to resolve this error with the information provided in the appended error log). Any help would be appreciated. APPLICATION SUMMARY * Online only application. * Browser-hosted application. ERROR SUMMARY Below is a summary of the errors, details of these errors are listed later in the log. * An exception occurred while downloading the application. Following failure messages were detected: + Exception occurred during store operation. + ...Show All
SQL Server Your login attempt was not successful. Please try again
I have a standard Login ASP.NET 2.0 control on a login Page, a LoginName and LoginStatus controls on the member's page. once the user login successfully I am redirecting the user to Member.aspx page. The following is my machine configuration Windows XP Pro Service Pack2 IIS 5.1 SQL Server 2000 visual Studio 2005 DISABLE ANONMYOUS ACCESS IN IIS ENABLE WINDOWS AUTHENTICATION I am Using form authentication, and I am getting following error "Your login attempt was not successful. Please try again". To debug,I am displaying the follwoing properties Membership.ValidateUser(Login1.UserName, Login1.Password) : - True HttpContext.Current.User.Identity.Name : - // is blank FormsAuthentication.FormsCookieName : - SqlAuthCo ...Show All
Windows Forms Process arrow key combination
Hey, I am trying to process arrow key combinations (for example when a user presses Up and Right). The KeyDown event will not work because it does not handle the arrow keys. ProcessDialogKey will not work because it is fired seperatley for each key (so once for up and once for right). I could do a timer to make see if the keys were pressed quickly but that seems over complicated for something like this. Does anyone have any ideas on how this can be done easier Thanks. Hello All. zenox: I don't think so, because I don't think that there is any event for simultaneous key presses. Each key will fire its own event, so you're going to have to check the state of at least one of them. From looking over ...Show All
Software Development for Windows Vista DWM Live Thumbnail Capturing?
Hello all! Is there a way to capture the live window content we can get from a DWM Thumbnail As I understand it, the live thumbnail is slapped on the window area during the composition process, so any capture methods would require DWM APIs exposing said functions. Perhaps it would be a good idea to have a function that returns a HBITMAP for saving to disk, or saves the file directly given the path and file type. It would be useful to have such an API for screenshot programs: select a window and have a screenshot taken, including the transparent frame regions that DWM gives to thumbnails. Thanks, Karl There is a lot more that we can and will do with the DWM in future releases, but, of cour ...Show All
Visual Studio Tools for Office VSTO 2007 Data Architecture Question
from an architectural point of view, is it possible for me to develop an application using Outlook 2007 as the UI, but to store all the data from my custom form regions inside a third party database. in this scenario, i would not be creating any Outlook message items and would not be saving them to the default data store. I would create a dummy MAPIFolder to allow me to insert a custom NavigationItem. But when users searched on this folder or requested a View from it, I would be searching directly on the database. is this feasible, and is this an approved way to do things thanks. hi - please let me rephrase this post in case it was confusing. my aim was to use Outlook 2007 purely as a UI. i wa ...Show All
Windows Forms Issue with DataGridView / CellMouseClick
There is an issue with DataGridView / CellMouseClick. If there is context menu attached to DataGridView, the event is not fired on right mouse click. Left mouse click still fires it. A workaround is to display context menu on CellMouseClick fire. The reason to use this event is to workaround another issue with DataGridView control. Normally user would expect right-clicking on a row to show a context menu (with disabled or enabled menu items) for that row. Yes, but... no. Right clicking doesn't change current row, so context menu has choices as to the current row of control, and not the clicked one. We use CellMouseClick in order to make clicked row current, but then there is a choice: to have contex ...Show All
Visual Studio Team System Trying to propagate changes between various release versions?
Here is the scenario I am thinking of: I want a single mainline (dev line) for ALL releases and branches created for each minor version. All these versions are branched off the mainline, so there is no direct parent-child relationship between two release versions. Let's say v1.8 is the current version released to production. A bug is discovered in v1.3 This is fixed in the v1.3 branch and the change is merged back to the mainline. Now how will the changes relating to this bug fix alone be integrated into v1.4 (and later versions). The mainline at the present is vastly different from v1.4 so doing a merge would result in many other changes also being added to the v1.4 branch. Can this be accomplishe ...Show All
SQL Server Expanding All SubQuery Nodes In Reports
Hi Everybody, I've got a report that builds out top level data and adds the plus symbol (+) for collapse/expand next to each of the rows for me to display a detail level tied to that record. The problem is when we do an export or print, it only applies to the top level instead of all of the detailed information. Is there a way to automatically expand all tree-nodes in a report for these subqueries Thanks in advance. Best Regards, Justin Thanks again for your quick reply - this forum is a life saver! I've got the visibility dialog up, but I'm not sure how to change it to 'Expand All'. Currently the Visibility radio button is set to 'Visible'. Is there an expression, or something els ...Show All
Visual C# & symbol not displaying on a label
I have a label that displays a description from a field in database. Noticed if the description has a & symbol it does not display in on the windows label control. How do I get & symbol to display on the label Thanks ...Show All
Visual Basic Question on message box
Hi, im doing a web based personal info form. it allows users to enter their names, email , weburl and other info. the progam will check if the user enter correct info. for example in a email textbox , the user will need to enter a @ sign for email to work. else a error message will pop up. but since there are many textboxs need to be check each would pop a message box telling the user where they did wrong, i want to know if there is any way after i click the submit button that all the error will appear in one message box. thank you I missed the web reference. Use the URL as per ahmedilyas post. As per web page validation There are out of the box validation controls you can use for in page control validatio ...Show All
SQL Server Records from internal Table not output in order to flat file
Hi - I have a SSIS package that dumps data from an internal table to a flat file output using standard data flow tasks. The entire table is output - no special SQL. Most of the time the records are placed in the output file in the same order as the internal DB table, but occasionally the order appears to be more random. When that happens, the record order in the internal table is correct - it is just the output. I can find no properties that seem to affect this. I would appreciate any hints and advice that anyone can give me. Has anyone else encountered this same problem Thanks in advance, Jim Sweeney Jim SweeneySLC wrote: Hi - I have a SSIS package that dumps data from an inte ...Show All
.NET Development Calling C# webservice from Visual C++ 6 using SOAP
Iam trying to call a C# DotNet 2003 webservice from Visual C++ 6 app (used win32 console, mfc, atl_mfc dll) using Soap toolkit 3. The webservice takes a String input parameter and returns a String. The input parameter I pass through C++ is always recieved as NULL in C# webservice while the output is working fine and it is returned back in C++. I have even tried with wsp wizard using atl_mfc dll and vb GUI but input always failed. It didn't give any error either. It will give an error when I output, input parameter as it is without appending to a string, then it will say Invalid pointer error in C++ app. Plz anybody can help in this regard. A bundle of thanks. My C# webservice code is as, it is a simple ASP.NET web service generated thro ...Show All
SQL Server Problems while installing sqlexpr.exe...
Hi! I am trying to install sql express using sqlexpr.exe (sp1). I used the following command: sqlexpr.exe -q /norebootchk /qn reboot=ReallySuppress addlocal=all instancename=TEST SECURITYMODE=SQL SQLAUTOSTART=1 SAPWD=pass@123 It is not installing and the logfile shows the following error: ------------------------------------ Running: DetectLocalBootstrapAction at: 2006/8/19 1:21:55 Complete: DetectLocalBootstrapAction at: 2006/8/19 1:21:55, returned true Running: LaunchLocalBootstrapAction at: 2006/8/19 1:21:55 Error: Action "LaunchLocalBootstrapAction" threw an exception during execution. Error information reported during run: "c:\Program Files\Microsoft SQL Server\90\Setup Bootstrap\setup.exe" finished a ...Show All
