button image w/o using PasteFace/Clipboard

  • Thread starter Jerry Nettleton
  • Start date
J

Jerry Nettleton

I'm using Office 2000 and have a COM add-in written in C++. Is there any way
to modify the toolbar button icon w/o using the clipboard and PasteFace()?
If not, do you have any sample code to save what's in the clipboard so I can
put the image there and restore the clipboard data after PasteFace.

Thanks,
Jerry
 
P

Peter Huang [MSFT]

Hi

Based on my research, it seems that we have to use the clipboard to modify
the image, becaues Office did not expose interface for us to edit image in
the runtime.
If you still have any concern, please feel free to post here.

Best regards,

Peter Huang
Microsoft Online Partner Support

Get Secure! - www.microsoft.com/security
This posting is provided "AS IS" with no warranties, and confers no rights.
 
J

Jerry Nettleton

This solution worked most of the time except when it came to the CF_BITMAP
format. I am looking for an ATL sample that shows how to copy a bitmap
to/from the clipboard.

Any samples?

Thanks,
Jerry
 
P

Peter Huang [MSFT]

Hi

Based on my research, I did not find such a ATL sample, but here goes the
code use the clipboard API to do the CF_BITMAP

Place a bitmap image on the clipboard (uses OLE)
http://www.codeguru.com/Cpp/W-P/clipboard/article.php/c3005/

Reading and writing a bitmap
http://www.codeproject.com/clipboard/clipboard_faq.asp#readwritebmp


Best regards,

Peter Huang
Microsoft Online Partner Support

Get Secure! - www.microsoft.com/security
This posting is provided "AS IS" with no warranties, and confers no rights.
 
C

chetan

Hi Jerry Nettleton,

I am also facing same problem.

Did you find any solution for this? If yes please tell us how to se
icon/image on toolbar button in Office 2000.

Chetan Shind
 

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