Icon for an Outlook addin

E

Eric Indiran

I'm writing an addin for Outlook in C++. I'd like to specify an icon to be
displayed on the toolbar button. How is this done?

Microsoft.Office.Core.CommandBarControl does not appear to have a property
to set the icon.

Thanks much,
-Eric
 
E

Eric Indiran

I was able to use the "PasteFace" method against a CommandBarButton to get
this to work.

Feels like a hack not to have a method that takes a HBITMAP directly and
instead rely on the system's clipboard to pass the image to a button...

-Eric
 
D

Dmitry Streblechenko

In Outlook versions prior to 2002, copy the bitmap to the clipboard, then
call CommandBarButton.PasteFace.
In Outlook 2002 and up, use CommandBarButton.Picture and
CommandBarButton.Mask properties.

Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top