harbar.net component based software & platform hygiene

Right-click a .WSP to Add Solution

Print | posted on Wednesday, April 25, 2007 12:18 PM

As I hope you are all aware, WSS Solution Packages (WSPs) are the solution to world hunger. Well not quite, but these CAB files on PCP are the way to package and install SharePoint custom code. If I was an American, I'd say that they "rock!".

Despite the numerous benefits they offer, they are still a little esoteric in so much as a command line is needed to add them to the Solution Store. Once they are there, you can use Central Administration to deploy the solutions to your Web Applications. Lars has his Solution Installer, a very nifty solution (no pun intended) for delivering your stuff to clients, but overkill for a development box.

Now running STSADM is no biggie, and some folk who just plain like more typing than neccessary will never use this, but to save a bit of time I've created a simple .REG file, which when merged into your regsitry allows you to right-click the .WSP and choose Add Solution.

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\.wsp]
@="wspfile"

[HKEY_CLASSES_ROOT\wspfile\shell]

[HKEY_CLASSES_ROOT\wspfile\shell\Add Solution]

[HKEY_CLASSES_ROOT\wspfile\shell\Add Solution\command]
@="C:\\Program Files\\Common Files\\Microsoft Shared\\web server
extensions\\12\\BIN\\stsadm.exe -o addsolution -filename \"%1\""