Vincent Croft
2005-09-21 17:09:04 UTC
I am writing a generic Office 2003 AddIn in .NET that creates a toolbar and
menu. The toolbar/menu items are bound to events handlers of type
_CommandBarButtonEvents_ClickEventHandler.
For Powerpoint and Excel everything is fine. However, for Word when a new
document is opened, the toolbar and menu items do not seem to get bound to
the events. I think this is probably a result of the the non mdi nature of
Word.
I can't find any documentation about this or how to work around it.
Is it a known issue (aka 'feature'?)
I have tried to work around it by removing and rebinding the events each
time a document loses/gains focus but this is not as straightforward as you
might imagine and in some scenarios event handlers get bound up twice
resulting in 2 events firing rather than one.
Any help or guidance would be much appreciated.
menu. The toolbar/menu items are bound to events handlers of type
_CommandBarButtonEvents_ClickEventHandler.
For Powerpoint and Excel everything is fine. However, for Word when a new
document is opened, the toolbar and menu items do not seem to get bound to
the events. I think this is probably a result of the the non mdi nature of
Word.
I can't find any documentation about this or how to work around it.
Is it a known issue (aka 'feature'?)
I have tried to work around it by removing and rebinding the events each
time a document loses/gains focus but this is not as straightforward as you
might imagine and in some scenarios event handlers get bound up twice
resulting in 2 events firing rather than one.
Any help or guidance would be much appreciated.