Search code examples
c#.netvisual-studio-2013vstoinstallshield-le

Excel VSTO addin deployment error


I am developing a plug-in (ribbon) for Excel in Visual Studio 2013 using C# and VSTO. So far, so good. Now, I want to create an installer. I am using InstallShield Limited Edition for Visual Studio. I followed the instructions given here http://msdn.microsoft.com/en-us/library/cc442767.aspx (Per-user installation, application-level add-in).

The compilation and setup work out without any problems. However, when I open Excel, I get this warning:

Name: 
From: file:///C:/Program Files (x86)/DCDB/ExcelInterface.vsto

************** Exception Text **************
Microsoft.VisualStudio.Tools.Applications.Deployment.InstallAddInFailedException: The customization cannot be run because 
the solution ID in the document does not match the customization. Contact your administrator for further assistance.
    at Microsoft.VisualStudio.Tools.Office.Runtime.OfficeAddInDeploymentManager.RefreshCustomization(Customization cust, 
AddIManifestsDownloadedArgs args)
    at 
Microsoft.VisualStudio.Tools.Office.Runtime.OfficeAddInDeploymentManager.OnAddInManifestsDownloaded(AddInManifestsDownloade
dArgs args)
    at 
Microsoft.VisualStudio.Tools.Applications.Deployment.ClickOnceAddInDeploymentManager.RaiseOnAddInManifestsDownloadedEvent(I
ClickOnceAddInInstaller addInInstaller, Uri deploymentManifestUri, AddInInstallationStatus addinSolutionState, String 
productName, String deploymentManifestXml, String applicationManifestXml, String hostManifestXml, String logFilePath, 
String version, Uri supportUri)
    at Microsoft.VisualStudio.Tools.Applications.Deployment.ClickOnceAddInDeploymentManager.InstallAddIn()
    at Microsoft.VisualStudio.Tools.Office.Runtime.SolutionInstaller.<>c__DisplayClass7.    <Install>b__0()

I have been searching on the net and there is no answer, only questions. I cannot understand the nature of the error message. Any ideas?


Solution

  • For anyone out there that encounters this problem in the future. I found that the problem is not a real problem. I was able to close the error message and open the Excel File directly and it worked fine.

    I did add the solution ID to the Manifest value after the the filename: file:///[INSTALLDIR]ExcelWorkbook.vsto|SOLUTIONID|vstolocal. But I'm not sure that actually made a difference. I still got the same error.

    I added a shortcut to the ExcelWorkbook.xlsx to the end users desktop which helped to ensure that the end user will open the Workbook directly, and not Excel.