Our development machine is 64 bit hardware running Windows 7 Professional N (64 bit), 64 bit Office Professional 2010 and Visual Studio Professional 2010.
We created a Word 2010 (Application Level Addin) using .net framework 4 , Ribbons and windows installer targeting Office 2010 using this link http://msdn.microsoft.com/en-us/vsto/ff937654.aspx . We followed everything to the dot several times. For our installer
we selected .net 4 client profile and windows installer 3.1 as prerequisites, since Office 2010 has VSTO 4.0 runtime installed and .net framework 4 has no-PIA functionality. In launch conditions we checked for Office 2010 Shared PIA and Word 2010 PIA availability
using the appropriate component ids. Additionally we checked for VSTO runtime availability as is laid out in the link aforementioned.
Our addin loads and executes with full functionality from ONLY within Visual Studio debug (F5). Building the setup project creates the windows installer (msi). Installing it(msi) installs the addin on the machine without any errors either. However after installing
the addin when we try to open any Word 2010 document, we are witnessing the following behavior...
The first time we try open any Microsoft Word 2010 document, Word 2010 startup screen shows up and we can see our addin being loaded "Loading [Our]Addin" but then Word 2010 does not open. The startup screen disappears and no error message is displayed.
Opening the word document for the second time just fires up this message (no word 2010 startup screen this time) "Word experienced a serious problem with the '[Our] word addin' add-in. If you have seen this message multiple times, you should disable
this add-in and check to see if an update is available. do you want to disable this add-in?'
Clicking on No, briefly fires up the startup screen of Microsoft Word 2010 and then it stops loading again(disappears) Clicking on Yes, opens Word 2010 with the [Our] add in disabled. Verified by clicking File-Options-AddIns. Looked under Disabled Application
Setting VSTO_SUPPRESSDISPLAYALERTS=0 and VSTO_LOGALERTS=1 was of no use either. We checkeed our Temp directory, there were no logs.
I installed and set up vsto troubleshooter (Windows PowerShell) from this link http://code.msdn.microsoft.com/vstotroubleshooter . The following is the output of
".\vstroubleshooter.ps1 info Word" when [Our] addin in disabled in Word 2010.
I'm surprised why [our] addin still shows load behavior 3 and is not listed under Disabled or Hard Disabled AddIns.
Next, since the above method did not work I downloaded the sample project from this link http://code.msdn.microsoft.com/VSTO2010MSI named 'Deploying a VSTO 2010 solution for Office 2007/2010 using Windows Installer' and used the appropriate project found
under Office Development - Setup and Deployment Projects Samples\FX40\AddIn Deployment\All User Install for 64-bit Office.
Initally I tested the solution to correctly load the demo excel 2010 add in project by creating and running the installer(msi) Then we added our Word AddIn project to the solution file by file and built it correctly (CTRL+SHIFT+B). It even ran from visual studio
debug (F5) correctly. Then we reconfigured the existing set up project to delete the demo excel project and load our word Addin primary output, [OurAddin].vsto and [OurAddin].dll.manifest files. We refreshed project dependencies and took appropriate
steps to exclude relevant files. We kept the registry checks intact and added launch conditions to check for Word 2010 PIA.
The installer built successfully (msi), installed without errors but unfortunately we witnessed the exact same behavior of Word 2010 as described previously.
We tried debugging using windows event logging http://msdn.microsoft.com/en-us/library/cc442816.aspx .
However I found this link where Hamed Ahmadi explains this is no cause for an Addin not to load. http://blogs.msdn.com/b/vsto/archive/2010/04/06/why-is-frameworkversionmismatchexception-thrown-hamed-ahmadi.aspx
We need to create an installer for our Word addin for both 32-bit and 64-bit Word 2010. Any guidance would be appreciated.