24

As in the title. Is it possible? When I rightclick on Visual Studio in a Taskbar I have a "Recent" category there i have but 1 .cs file that I can pin.

Now the question is: what to do to pin a .sln solution there?

Mikeon
  • 9,632
  • 6
  • 22
  • 31
  • 1
    +1 So hopes this gets answered! Been bugging me a while! – Daniel Elliott Sep 10 '09 at 08:21
  • This should probably be moved to superuser.com – bobbymcr Sep 10 '09 at 08:31
  • well I asked simialer, but more general question there where I got pawned with down votes for threatning people with bad karma :-) http://superuser.com/questions/38617/where-does-windows-7-taskbar-store-its-data – Mikeon Sep 10 '09 at 09:07

6 Answers6

21

If you pin the VSLauncher.exe to the taskbar (drag it in) you will get recent projects and solutions on the right click menu.

You can find this exe in your program files / common files directory. Mine is in

C:\Program Files\Common Files\Microsoft Shared\MSENV\VSLauncher.exe

You can also do this by dragging a solution into the task bar (which does the same as the above). If you do this rightclicking it will show recent projects and solutions.

Hope this helps.

Steve Psaltis
  • 635
  • 4
  • 8
  • This one works if I use the pinned solutions, but if I just click on the icon - it shows me a message box complaining about missing file: The following files were specified on the command line: [empty space - nothing in it] These files could not be found and will not be loaded. – Mikeon Sep 10 '09 at 11:31
  • 2
    There is another drawback - when a solution is opened, another VS icon shows up on the taskbar. The launcher icon stays inactive. – Vladimir Grigorov Feb 17 '12 at 13:31
  • This was the best (quickest/simplest) solution for me when using Visual Studio 2012 – Bern Sep 19 '12 at 08:47
4

This is for Visual C++ 2008 Express Edition. You may adapt for other editions.

reg add HKCR\.sln\OpenWithProgids /v VCExpress.dsw.9.0

karyonix
  • 41
  • 1
  • I prefer this method, since you don't have to override your default program for `.sln` files and you don't have to drag another program to your taskbar. – palswim Jun 22 '11 at 15:54
  • More generically, just add the appropriate class to `[HKEY_CLASSES_ROOT]\.sln\OpenWithProgids` as a String value, whether it's "VCExpress.dsw.9.0" or "VisualStudio.dsw.9.0" or something else. – palswim Jun 22 '11 at 16:35
2

This is an old question, but I found a way avoid the drawback to the accepted answer that Vladimir Grigorov mentioned in a comment, that an additional VS icon shows up on the taskbar.

Instead of pinning VSLauncher.exe, pin

devenv.exe

(C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE)

to the taskbar.

Now drag your solution onto the VS icon in the taskbar. You should see a tooltip saying "Pin to Microsoft Visual Studio 2010". Using this method will let you pin solutions to the taskbar without showing additional VS icons on the taskbar.

Winks
  • 369
  • 1
  • 3
  • 15
1

To expand on karyonix's answer:

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\VisualStudio.sln.9.0]
@="Microsoft Visual Studio Solution"
"InfoTip"="prop:Size;Type;DocComments;Write"
"TileInfo"="prop:Type;DocComments;Size"

[HKEY_CLASSES_ROOT\VisualStudio.sln.9.0\shell]

[HKEY_CLASSES_ROOT\VisualStudio.sln.9.0\shell\Open]

[HKEY_CLASSES_ROOT\VisualStudio.sln.9.0\shell\Open\command]
@="\"c:\\Program Files (x86)\\Microsoft Visual Studio 9.0\\Common7\\IDE\\devenv.exe\" \"%1\""

[HKEY_CLASSES_ROOT\VisualStudio.sln.9.0\ShellEx]

[HKEY_CLASSES_ROOT\VisualStudio.sln.9.0\ShellEx\IconHandler]
@="{9A2B23E4-2A50-48DB-B3C3-F5EA12947CB8}"

[HKEY_CLASSES_ROOT\VisualStudio.sln.9.0\ShellEx\PropertyHandler]
@="{9A2B23E4-2A50-48DB-B3C3-F5EA12947CB8}"

[HKEY_CLASSES_ROOT\.sln\OpenWithProgids]
"VisualStudio.sln.9.0"=""

Note the reference to Program Files (x86) - adjust if you're not running 64-bit Windows.

This adds Visual Studio 2008 to the "Open With" menu, and enables recent solutions in the right-click menu.

Community
  • 1
  • 1
Blorgbeard
  • 93,378
  • 43
  • 217
  • 263
1

The VSLauncher.exe needs a solution or project path to do anything usefull. In the right click of the taskbar item you can right click the microsoft version selector and click properties. There you will then be able to give it a path by editing the target field. This will stop you getting the error.

This is all based on adding one solution to the task bar as per your question. I did not find a way of adding more than one!

Hope this helps.

Steve Psaltis
  • 635
  • 4
  • 8
1

Just wanted to add to Blorgbeard and karyonix that this definitely works, and here's how I modified it to work with VS 2005 sln files:

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\.sln]

[HKEY_CLASSES_ROOT\.sln\OpenWithProgids]
"VisualStudio.sln.8.0"=""

[HKEY_CLASSES_ROOT\VisualStudio.sln.8.0]
@="Microsoft Visual Studio Solution"
"InfoTip"="prop:Size;Type;DocComments;Write"
"TileInfo"="prop:Type;DocComments;Size"

[HKEY_CLASSES_ROOT\VisualStudio.sln.8.0\shell]

[HKEY_CLASSES_ROOT\VisualStudio.sln.8.0\shell\Open]

[HKEY_CLASSES_ROOT\VisualStudio.sln.8.0\shell\Open\command]
@="\"D:\\Program Files (x86)\\Microsoft Visual Studio 8\\Common7\\IDE\\devenv.exe\" \"%1\""

[HKEY_CLASSES_ROOT\VisualStudio.sln.8.0\ShellEx]

[HKEY_CLASSES_ROOT\VisualStudio.sln.8.0\ShellEx\IconHandler]
@="{9A2B23E4-2A50-48DB-B3C3-F5EA12947CB8}"

[HKEY_CLASSES_ROOT\VisualStudio.sln.8.0\ShellEx\PropertyHandler]
@="{9A2B23E4-2A50-48DB-B3C3-F5EA12947CB8}"

Make sure you edit the command path correctly, because for 2005 the folder is Microsoft Visual Studio 8, not 8.0

grimmdp
  • 221
  • 2
  • 3