Hey Zack,

Yeah, it definately would be interesting to be able to do this. The best I've come up with is either:

(1) Have the Button call a Macro in a standard XLA, say "MyMacro". Then MyMacro() then calls MyComAddin.MySub().

(2) Avoid the entire .OnAction() concept and instead hook onto whatever Buttons are required via 'WithEvents'. So a COM Addin during startup needs to either identify the buttons it is interested in and hook into it, and/or create it's own buttons as needed.


Calling "MySub()" directly from the .OnAction would be neat, but I have not succeded in working that out nor has anyone I've seen been able to do it. It would be nice, for you would be able to type in the .OnAction for a CommandBar button manually and it would be saved for future sessions, but, well, I can't quite see how to make it work. And it might not be possible, I don't know.

But since there are other ways of dealing with it, I don't think it's a major issue. A curiousity though...