Let’s Deploy VSTO – Deployment via Regedit

For a very long time I had a question to “How to deploy a VSTO add-in only via registry entries?”
Seems like I found an answer henceforth I am posting up this blog for the very same question.

Step 1: Build your solution to generate the following files.

image1.jpg

Step 2: Open the Regedit and navigate to the following location, according to your choice of application add-in you are developing and willing to deploy.
Excel: HKEY_CURRENT_USER\Software\Microsoft\Office\Excel
Word: HKEY_CURRENT_USER\Software\Microsoft\Office\Word
PowerPoint: HKEY_CURRENT_USER\Software\Microsoft\Office\PowerPoint
Outlook: HKEY_CURRENT_USER\Software\Microsoft\Office\Outlook

Step 3: Create the following entries:

    1. Create a unique key name under the AddIns folder

image2.jpg

    2. Create the following entries under the newly created key

   Description (String), FriendlyName (String), Manifest (String) & LoadBehavior (DWord)

image3.jpg

    For explanation refer to following link

   http://msdn.microsoft.com/en-us/library/bb386106.aspx

Step 4: Navigate to the following location in the registry

HKEY_CURRENT_USER\Software\Microsoft\VSTO\Security\Inclusion

Step 5: Generate a new GUID via visual studio GUID generation tool

image7.jpg

Step 6: With the new GUID create a new key, under the location navigated earlier in step 4.

image4.jpg

Step 7: Under the new key create the following entries
url (String), PublicKey (String)
image5.jpg

Step 8: To obtain the public key specific to your add-in, open the *.vsto file in your solution Debug/Release folder and obtain the following pattern string as it is and copy it in the PublicKey entry mentioned in the step 7 above.

image6.jpg

Step 9 (Last One): Finally last, but not the least. Create the following illustrated registry enteries, as created upon your development machine. These keys are used for trsuted publisher setup of the VSTO addin and once recreated on the user PC, as same on the development machine the office application is good to go for the VSTO tool created.

image8.bmp

image9.bmp

And finally open the application of your choice for which you followed the above steps and you add-in should start-up as required along with the application.

Leave a Reply

Your email address will not be published. Required fields are marked *

*