views:

506

answers:

2

Hi,

This one seems to be quite ridiculous but how can I open a VS solution file in Windows Vista double-clicking on it?

Every time I do I got a strange error that the file doesn't exist. I'm pretty sure this is a Vista configuration but I couldn't find any relevant information.

It's really annoying having to open the VS IDE every time you want to open a solution. I'd rather just click on the file and that's it !!!

Cheers.

+4  A: 

Right click on the solution file ---> properties--> Change --> VS exe----> click the box to use as default

In vista you need to "Run As Admin" as well

EDIT: you dont need to start each project as Admin you just need to be sure your VS process is running as admin

cgreeno
You certainly don't, in general, need to run VS as admin.
Will Dean
Sorry...right click on where?
afgallo
I didnt mean to imply you need to start each project- you do need to run VS as admin or else you will have issues with the debugger....
cgreeno
I think you didn't understand my question .... I already run VS as admin ... The problem is when opening the solution file itself...I can't do that in windows explorer...I have first to start the IDE and the pick my solution file. ....
afgallo
The "Run as Admin" comment was more of an after thought that can cause issues if it is not done
cgreeno
dude all you have to do RIGHT CLICK on the solution file and re-associate the VS EXE with it!
cgreeno
now we're on the same page ... thanks for editing the answer with "right click on the solution file"
afgallo
@Chris, you do not need to be admin to use the debugger for most tasks.
JaredPar
@JaredPar if you do not "Run as Admin" in Vista the debugger will not attach itself to a process properly - you will need to do it manually each time
cgreeno
+4  A: 

If you set the VSLauncher to run as admin, the double-clicking will work. \Common Files\microsoft shared\MSEnv\VSLauncher.exe. Right-click and set the file to run as admin. This is a problem with VS2005 solutions because VS2005 always needs to run as admin on Vista. VSLauncher is responsible for reading the metadata in the .sln file to determine which version of devenv.exe to execute. Since the devenv.exe for VS2005 needs to run as admin, VSLauncher.exe must run as admin in order to launch it.

Darren Stokes
My angle brackets were stripped out. The Common Files directory is under Program Files, not at the root.
Darren Stokes
This is the answer I needed for opening solutions in Windows 7. Thanks!
Evil Pigeon