visual-studio-2008

How should I deploy an MFC application?

I created an application in VS 2008 Express as an MFC app just to take advantage of the easy GUI creation. I might re-do this app in pure win32 since no other MFC classes are used (just a button and a text box, the button fires off the main program, all win32). My only question that determines whether I stay in MFC or port it over to pur...

Visual Studio 2008 (C# @ Verbatim) Fonts and Colors option

I just read secretGeek's fun post on 8 ways to be a better programmer in 6 minutes and really liked the tip on making hard-coded strings look ugly. When I tried to change the Fonts and Colors setting to do this in my copy of Visual Studio 2008 Professional, I found that the String (C# @ Verbatim) option was not in the Display items list...

How can I create a wizard in .NET?

How can I write a wizard in Visual Studio/.NET to generate code and insert it in a form? ...

How can I tell which class methods aren't being used?

Over time I tend to create methods that are no longer useful to me. I think I have moved all my code away from them but maybe not. Or, maybe the code references the old method and everything works fine until I hit that special thing that made me create a new method. Is there anyway besides just using find on each method, to see what i...

Visual Studio 2008 Product Key in Registry?

I have a friend who needs to reinstall windows, but he can't find his VS2008 activation code/product key. Is there a way to look up which product key he entered when he last installed VS2008 in the registry? Any other method of finding the key is also welcome. ...

Prevent solution explorer from hiding when debugging

When I debug in Visual Studio the Solution Explorer is closed. How do I make it stay open? ...

Visual Studio 2008: Synchronizing project structure with underlying file structure

Is there a way of making the (ASP.NET MVC) project structure reflect the underlying physical directory in the same way as ASP.NET Website projects are treated? - so you don't have to explicitly add files that are already in place via the Solution Explorer too. Thanks ...

Filling tableadapter with stored procedure takes signifigantly longer than running stored procedure in SQL

I have been trying to fill my ultracombo box with data yet it takes a signifigant amount of time. However when I run the same stored procedure from withing sql server it takes relatively no time. The line of code that the program gets hung up on is: SprocPatientsTableAdapter.Fill(Me.PatientsDataSet.sprocPatients, SelectedCustomerID) B...

How to have comments in IntelliSense for function in Visual Studio?

In Visual Studio and C#, when using a built in function such as ToString(), IntelliSense shows a yellow box explaining what it does. How can I have that for functions and properties I write? ...

Relating mismatched column in an xsd?

I am using VS 2008 and trying to create a dataset for ms sql reporting services. I have two tables that I want to relate. One has a column with type of int, the other shortint. VS give me an error of "Parent and Child columns don't have type-matching columns." Is there any way to over ride this? In old sql reporting services I could...

How do you prevent the Visual Studio designer auto-generating columns in a DataGridView?

I generate all my columns in a subclassed DataGridView programmatically. However Visual Studio 2008 keeps reading my constructor class (which populates a DataTable with empty content and binds it to the DataGridView) and generates code for the columns in the InitializeComponent method - in the process setting AutoGenerateColumns to false...

Going from VisualStudio generated Database stuff to Programmer Generated

I'd like to be able to better access the database so I can execute queries (primarily because I don't understand/know the API for it, but I do know SQL). I don't want to remove everything Visual Studio has done because a lot is already built upon it, but how can I get an object that I can use to execute SQL queries. This is Visual Studi...

Including Views in a Class Library

In a previous question I found out how to create a plugin architecture for MVC. I'm not the whole way down that path yet but I do have a nice way of splitting things up. One thing that is bugging me though is the intellesense for the View when they are in the Class Library. Developing them in the core MVC project and then copying them a...

How to prevent VS2008 from saving bookmarks?

Hi All, VS2008 automatically saves bookmarks and restores them when I reopen the document. How can I tell it to stop saving them. When I open a doc, I want it without any bookmark, as in previous versions of VS. I went twice through the whole options set but couldn't find anything related to bookmarks. TIA. ...

WCF consumed as WebService adds a boolean parameter?

I've created the default WCF Service in VS2008. It's called "Service1" public class Service1 : IService1 { public string GetData( int value ) { return string.Format("You entered: {0}", value); } public CompositeType GetDataUsingDataContract( CompositeType composite ) { if ( composite.BoolValue ) ...

Wildcard usage for find and replace

I have a get method in my code which is currently taking a parameter. I want to remove this parameter from this method. For this I have to update all those pieces of code where this method is used. I tried find and replace in VS2008 with the wildcard option as get(?*) to get(). But unfortunately this is matching for if(get() > 1) type of...

Weird behaviour of C++ destructors

#include <iostream> #include <vector> using namespace std; int main() { vector< vector<int> > dp(50000, vector<int>(4, -1)); cout << dp.size(); } This tiny program takes a split second to execute when simply run from the command line. But when run in a debugger, it takes over 8 seconds. Pausing the debugger reveals that it is ...

Change Local path, team explorer

Does any one know how to change the local path of the downloaded project in team explorer 2008. I downloaded a project to a wrong directory, now i deleted it and did get latest but i get a message "All files are up to date" Thanks -Mithil ...

Why does Visual Studio debugging mode does not work properly (performing F5 when F11 was pressed)

Hello. I've faced the strangest problem with Visual Studio C# debugger in my career. In short after break point in my code was hit I cannot step through the code. F11 (step into) and F10(step over) work for several times, but eventually VS performs F5 (continue) action. I still able to debug using break point on every line. This behavi...

VS 2008 Encoding and MSBuild Exec Task

I have a msbuild exec task that calls a cmd file to setup my database. I am using the msbuild exec task like this: <Exec Command="$(SqlFolder)\Setup\SetupDatabase.cmd $(DBServer) MyDB $(SqlCmdRunner)" IgnoreExitCode="False"> <Output TaskParameter="ExitCode" ItemName="DBSetupExitCode"/> </Exec> In the setup cmd, it uses osql t...