Use devenv /edit to open any file in an existing Visual Studio instance (VSEdit functionality)

For those of you who used the VSEdit Powertoy for VS 2003, you’ll be happy to know that you can have similar behavior in VS 2005!

Just run “devenv.exe /edit <filename>” from the command line to open any file in an existing instance of Visual Studio 2005.

You may want to create a VSEdit command if you find yourself using this feature a lot.  Just create a file called "VSEdit.cmd" (you can use notepad to do this) with the following:

@"%Program Files%\Microsoft Visual Studio 8\Common7\IDE\devenv.exe" /edit %*

Also, place VSEdit.cmd in a directory that’s in your PATH (or add the directory to your PATH).

now you can do
vsedit <filename>

Comments (5)
  1. Travis Owens says:

    Of course you should have also pointed out that the VSEDIT PowerToy still works with VS2005 too. At least it does for me.

  2. Travis Owens says:

    the alias command doesn’t work for me in the command prompt nor the ‘Visual Studio 2005 Command Prompt’.

    Are you using an add on or resource kit tool?

    XP SP2 here.

  3. Dan McCarty says:

    Is alias an XP thing? Using 2K at work, my CMD window isn’t sure what to do with alias. Maybe I need to alias alias to something like alias. 😉

  4. saraford says:

    I’ve changed the alais tip to a VSEdit.cmd batch file idea. Internally we have an alias command, and i just forgot to check whether it worked in the outside world.

    Bad tester! No cookie for you. =)

  5. schildr says:

    You can alos set it up as an external tool.

Comments are closed.

Skip to main content