Customizing Shortcuts for Visual Studio

Heath Stewart

After installing the last several releases of Visual Studio, you’ll find shortcuts to command prompts that automatically set up the PATH, INCLUDE, LIB, and other environment variables. At least with Visual Studio 2010 these command prompts have larger buffers and enable quick edit mode, but some people like to customize these shortcuts to their liking.

Since Visual Studio installs for all users, these shortcuts are protected and can only be edited by administrators. In Windows 7 you are simply prompted to elevate; however, in Windows Vista with UAC enabled, when you try to edit the shortcut you may see the following error message.

Error Updating Shortcut

Unable to modify the shortcut: C:ProgramDataMicrosoftWindowsStart MenuProgramsMicrosoft Visual Studio 2010Visual Studio ToolsVisual Studio Command Prompt (2010).lnk.
Check to make sure it has not been deleted or renamed.

OK

To customize the shortcut, you should copy it to a user-writable location. You should not modify the protected shortcut as that could cause it to be left behind if you ever uninstall Visual Studio. But rather than have a second entry in your Start Menu you can keep the same name and it will show up instead of the per-machine copy.

  1. Find the shortcut. The easiest way is to just press the Start button and type “Visual Studio Command Prompt”.
  2. Right click and select Copy.
  3. Right click on All Programs at the bottom of the Start Menu and select Open.
  4. Double click to open Programs.
  5. Click on the Organize button and select Paste.
  6. Right click on the shortcut and select Properties.
  7. Edit any of the properties you want, but do not change the name of the shortcut. For example, you can change the screen height to 60.
  8. Click OK to save the changes.

Now whenever you launch the shortcut from the Start Menu, you’ll be starting your copy with your changes. You’ll still need to delete your copy if you ever uninstall Visual Studio but now you can make all the changes you want without having to elevate.

0 comments

Discussion is closed.

Feedback usabilla icon