View Single Post
  #4  
Old January 30th 09, 02:53 PM posted to microsoft.public.outlook.program_addins
Ken Slovak - [MVP - Outlook]
external usenet poster
 
Posts: 5,848
Default Button throws error when image is added if there's no popup ob

You didn't answer my question, is m_OldEmailCSToolBar a CommandBar object?

So the code blows up on Outlook 2003 when you set .Picture. If you comment
out adding the image using .Picture everything's OK?

My guess is that you are actually in WordMail and that's the cause of the
error. Do you actually test for Inspector.IsWordMail() in your code?

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Professional Programming Outlook 2007.
Reminder Manager, Extended Reminders, Attachment Options.
http://www.slovaktech.com/products.htm


"Andrew" wrote in message
...
Thanks for the response,

m_OldEmailCSToolBar is a global variable in the wrapper class for the
inspector. Yes, it is an Inspector Object, its an existing email item that
was opened, so No "WordMail."

Yes, it blows up on the when I set the Picture property. I've stepped
through the code and all the objects are valid. As I mentioned earlier, it
works fine when I create a "CommandBarPopup," add the popup to the
"m_OldEmailCSToolBar" and then add the button to the "CommandBarPopup."
Now
that I'm leaving out the "CommandBarPopup," its blowing up.

As a note: the same code works flawlessly in 2007 version of the Outlook
Add-in.

Help


Ads