Is Outlook truly exiting? I never get persistent toolbars that weren't
supposed to be there. I do use Explorer.Close.
--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Absolute Beginner's Guide to Microsoft Office Outlook 2003
Reminder Manager, Extended Reminders, Attachment Options
http://www.slovaktech.com/products.htm
"Mark J. McGinty" wrote in message
...
"Mark J. McGinty" wrote in message
...
"Ken Slovak - [MVP - Outlook]" wrote in message
...
I always just delete the command bar, but I also set it as temporary when
I
create it.
Thanks for the reply, Ken.
A couple more questions, if I may... The temporary flag prevents the
bar/button definition from being persisted? Wouldn't that tend to make
removal unnecessary?
I take it you don't pay any attention to RemoveMode when the AddIn
disconnects?
Hmm, trying to remove them when (RemoveMode ext_dm_UserClosed) seems to
be a moot point, since that is the only way OnDisconnection fires while a
valid Explorer exists. I also noticed that removing CommandBars in
Explorer_Close fails with error: "The Explorer has been closed and cannot
be used for further operations. Review your code and restart Outlook."
I made both the buttons and the bars temporary (and manually deleted the
old bar.) The buttons go away when OL exits, but the bar persists, even
when the temp parameter to CommamdBars.Add is True.
Where do you remove your CommandBars?
-Mark
Thanks,
Mark
--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Absolute Beginner's Guide to Microsoft Office Outlook 2003
Reminder Manager, Extended Reminders, Attachment Options
http://www.slovaktech.com/products.htm
"Mark J. McGinty" wrote in message
...
Is there any good reason to delete all of the Controls in a CommandBar,
before deleting the CommandBar itself?
-Mark