Outlook Addin functions only one time after Outlook is started
"Mo" wrote in message
...
Mark,
I have try/catch in the code and there are no exceptions when I debug
it. The first time you click the add-in button everything works fine
and you can debug right through it. After that even in debug mode the
button click event is not triggered.
Weird. Maybe put a call th OutputDebugString() (Win32 API) in the class
destructor, or maybe a do-nothing line of code that you can set a breakpoint
on -- some way to know when the class unloads. Or maybe add a dummy button,
to give yourself a way into a breakpoint/a way to examine the object in the
debugger after it breaks.
Sadly, you couldn't fill a thimble with what I know specifically about C#,
but logically (or so it seems to me) either your class is being unloaded, or
whatever hooks it into the button is being lost/cancelled/overwritten.
Does myButton need to be declared at class scope, rather than function
scope? (I'm just grasping at straws, now.)
Sorry I don't have more for you.
-Mark
Mo
|