Visual Studio Solutions Tips

Español

Another (I think useful) tips for you Visual Studio

Create Visual Studio Solutions from Windows Explorer. This has the advantage that you can create the project folder structure that you want and then create an empty solution. I use this quite a lot because I use Solutions as diferent views of my projects (specially when they are big with a lot of visual studio projects). And it’s handy when you are using a folder structure for all your project and the visual studio solution is just the “code” part maybe in src directory.

To get to that create this registry key (you can copy this on a .reg file an execute that):

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\.sln\ShellNew]

“Data”=hex:EF,BB,BF,D,A,4D,69,63,72,6F,73,6F,66,74,20,56,
69,73,75,61,6C,20,53,74,75,64,69,6F,20,53,6F,6C,75,74,69,
6F,6E,20,46,69,6C,65,2C,20,46,6F,72,6D,61,74,20,56,65,72,
73,69,6F,6E,20,31,30,2E,30,30,D,A,23,20,56,69,73,75,61,6C,
20,53,74,75,64,69,6F,20,32,30,30,38,D,A,47,6C,6F,62,61,6C,
D,A,9,47,6C,6F,62,61,6C,53,65,63,74,69,6F,6E,28,53,6F,6C,
75,74,69,6F,6E,50,72,6F,70,65,72,74,69,65,73,29,20,3D,20,
70,72,65,53,6F,6C,75,74,69,6F,6E,D,A,9,9,48,69,64,65,53,6F,
6C,75,74,69,6F,6E,4E,6F,64,65,20,3D,20,46,41,4C,53,45,D,A,
9,45,6E,64,47,6C,6F,62,61,6C,53,65,63,74,69,6F,6E,D,A,45,6E,
64,47,6C,6F,62,61,6C,D,A

Or just take the file in the article of this guy that I google/find last time I had to edit this (you know when my freaking can’t wait this slow computer make me reformat again my lap hehe)

The second tips has to do with solutions again, if you already notice Visual Studio 2005 and further creates a top level Solution.root folder when you have projects in your solution and IIS Web Sites that are on another location (i.e. C:\Inetpub\wwwroot\…) I think that it’s not a very good practice this folder layout and when you upload this with Visual Source Safe and .root is created is more confusing for your development team. So if you take care of the solution and each project folder destination, even the destination of the web sites (I take the mapping of those manually, this way I have the web site project in as a subfolder, as any other project on the solution) you have to tell to Visual Studio not to create the .root folder:

Click Start, click Run, type Regedit, and then click OK.
Open HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\7.1\SourceControl
Select key DoNotCreateSolutionRootFolderInSourceControl, click Edit, and then click Modify.
In the Value data box, change 0 to 1, and then click OK.

(you have to change the version if have a newer Visual Studio, 7.1 correspond to Visual Studio 2005, the first Visual Studio with this behaviour.

References:

http://flux88.com/blog/right-click-new-visual-studio-solution/

http://msdn.microsoft.com/en-us/library/aa290096(VS.71).aspx

Advertisements

One thought on “Visual Studio Solutions Tips

  1. Pingback: Visual Studio Solutions Tips « Ernesto Ocampo Blog en Español

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s