1
votes

We have an application that is built with Excel as the front end using the Office object model. We were using a C++ shim to load it as a COM add in for Excel 2003, but I've updated it to use the latest VSTO for Excel 2007. I've also been using VS 2010 for the latest version. The problem is that everything works great on my dev machine in debugger mode as well as just launching Excel 2007, but I cannot get it to run on any other machine (my current target machine is Win7, development is XP). I've created a ClickOnce deployment of the Addin, and I can see it in the list of COM Addins, but when I check on it to load it nothing happens. I re-open the Addins manager and it is un-checked. I've also tried setting in in the registry, but as soon as I run it, it sets the registry back to do not load. I've tried everything I can think of and searched all over the web but no dice. Any help would be appreciated!

UPDATE: I was able to setup some VSTO Error notifications and I got this from my app as well as a basic Hello World app that I deployed with ClickOnce. I still haven't found an answer, but I do know that this errors out before the add-in can even fire the Startup event:

Microsoft.VisualStudio.Tools.Applications.Runtime.CannotCreateStartupObjectException: Could not create an instance of startup object PrevisionAddIn.PrevisionAddIn in assembly PrevisionAddIn, Version=6.0.0.0, Culture=neutral, PublicKeyToken=null. at Microsoft.VisualStudio.Tools.Office.Runtime.DomainCreator.ExecuteCustomization.CreateEntryPoint(String entryPointTypeName) at Microsoft.VisualStudio.Tools.Office.Runtime.DomainCreator.ExecuteCustomization.Microsoft.VisualStudio.Tools.Office.Runtime.Interop.IExecuteCustomization2.LoadEntryPoints(IntPtr serviceProvider)

2

2 Answers

1
votes

Can you disable the anti-virus software on the machine and see if that makes any difference? I have some add-ins that are deployed via ClickOnce, and one of them would never be enabled. My boss would go in and check "enable" on the screen in Outlook, and close the window, and go back in and it would be disabled. Turned out to be his anti-virus software being overzealous. Just an idea...

Also, you can't use ClickOnce for Office2003. Does this add-in still target 2003, or does it target 2007?

And if you're using ClickOnce, are you signing it with a valid certificate from a certificate authority such as Verisign? Or are you deploying to http://localhost and installing it from there (which doesn't require a certificate).

0
votes

I figured out that the problem was with the version of VS 2010 that I was using. I built the project in the Beta 2 version, and hadn't had time to upgrade. Once I did that, it worked as advertised. But I sure learned a boatload about how to get this thing up and running!

Thanks again!

-Erick