I’m in the process of learning how to create add-ins for Microsoft Office Word. I’ve created a simple Word 2010 Add-In project in Visual Studio 2010 which displays “Hello World” in a message box. Up to this point everything works fine. But if I want to change the message for instance from “Hello World” to “Hi” i get the following error message
System.Deployment.Application.DeploymentException: Unable to install this application because an application with the same identity is already installed. To install this application, either modify the manifest version for this application or uninstall the preexisting application.
After installing the add-in I do the following:
- Remove the add-in from Ms Word Options,Add-Ins
- Uninstall the add-in from Add Remove Programs
- Delete the Normal.dot file
- Delete the .vsto in my bin/Debug folder of the project
Once I re-run the project I get the error above.
I really don’t know where else can this plug in exist as I think I delete all possible places where any references to it could be found.
I’ve also tried running RegScanner and deleting all the registry entries pertaining to the add in,yet im getting the same error…
If anyone had this issue before and you know exactly how to solve it and what could be causing it please let me know!
I discovered that if you modify any code in a MS Word Add-in in Visual Studio and you want your changes to be updated in MS Word you can do the folowing:
In Visual Studio,change the version number in Project Name\Properties\Publish\Publish Properties.
Once the version number has been changed (e.g 1 0 0 1) rebuild the project in Visual Studio.
Navigate to ProjectFolder\bin\Debug and double click the .vsto file, voila! You get the following message – The Microsoft Office customization was successfully updated.If you view the .vsto file with a text editor you can also see that the version number has been changed to a new value,hence an update occurs when you double click the .vsto file.It picks up a new version number and re-installs the add-in and successfully attaches to Word.
If the above is the accepted way to do it, that’s fine, but I would still like to know whether there is any way that an add-in can be automatically updated in Word without changing the version number.Simply change code,rebuild project,install.