How do I shim a Excel automation addin that implements IDTExtensibility2 but is not a com add in?
- by Shane
I found this article http://blogs.officezealot.com/whitechapel/archive/2005/05/21/4728.aspx but the example given is a straight automation add-in that does not implement IDTExtensibility2. My add in implements IDTExtensibility2 to get access to the excel object model but is not installed as a COM add in so RegisterFunction for example will called when one of the add in functions is first used not when the excel starts as in the case of the a COM add in. Will this method described in the link above work in my case also?
I tried version 2.3.1 of the shim wizard which seems to have support for automations add-ins (it has a check box for automation add ins in the metadata import process). The generated shim runs (I can see breakpoints being hit in the debugger), but my functions no longer work (i get #NAME). The shims is installed as a COM add in and loads when excel starts so I suspect it's not doing what I want.