0

Is there any way to make a hyperlink from a website which would open visual studio and find a file / find a class in a project or so?

We have some code review protocols where there are names of the classes to review and it would be nice if you could just click on the link and it would lead straight into the visual studio instance.

  • There is no way a website can detect what application on your desktop (without any add-on installed). If you have Reshaprer, you can easily find a class or file by using Ctrl+T in VS. Shift+Alt+L to locate the file in solution. – Win Nov 19 '13 at 23:16

2 Answers2

0

You have to write a program that installs a URI protocol like vs://C:/Projects/myproject.sln&class=Class%20A that would open the Solution myproject.sln as described in http://msdn.microsoft.com/en-us/library/aa767914(VS.85).aspx!

With this sheme you have to register to open another manual written program (clicked on a vs://-link) to start the devenv process with some parameters. Take a look at this to get some more information about "Opening a file in a project from the CMD".

Conclusion: There is no way to do this without installing a program and a macro in Visual Studio.

Community
  • 1
  • 1
0

You can check devenv.exe start up switches(parameters) here:

http://msdn.microsoft.com/en-us/library/xee0c8y7(v=vs.90).aspx

http://msdn.microsoft.com/en-us/library/19sf6kk3(v=vs.90).aspx

Also you can use ActiveX to run CMD commands to invoke the devenv:

How to Run cmd.exe with parameters from javascript

I hope this helps :)

Community
  • 1
  • 1
Mahmoud Fayez
  • 3,398
  • 2
  • 19
  • 36