Tuesday, November 15, 2011

How to change “devenv” command location?

You can follow these steps to open VS208 from the command prompt using "devenv":

1. Open the Registry Editor by typing regedit on Run

2. Locate and open the following key:

3. My Computer\HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\devenv.exe

4. Currently for VS 2005, devenv.exe is mapped to

5. C:\Program Files\Microsoft Visual Studio 8\Common7\IDE\devenv.exe

If you want open VS 2008 from the command prompt, you must change the map to

C:\Program Files\Microsoft Visual Studio 9.0\Common7\IDE\devenv.exe

Just change to 8 to 9.0 to switch from VS 2005 to VS 2008, or VS 2008 to VS 2005.