Extracting commandbar FaceIDs for use as image in an image control

I've figured out how to extract both the PICTURE and MASK properties of the FaceId of any of the Office commandbar controls, and save those two properties as images on my computer.

        Set ctrl = CommandBars.FindControl(Id:=rs!FaceId)
        stdole.SavePicture ctrl.Picture, "E:\TempPic.bmp"
        stdole.SavePicture ctrl.Mask, "E:\TempMask.bmp"

But what I want to do is create an image picker that displays a set of these images in a form, either in an image control or as the picture property of a command button.  Unfortunately, neither the image control or the command button has a Mask property, so the background of all of the picture images are black, rather than what they are supposed to be.  The attached image shows the first 15 faceIDs, with the top row displaying the image saved with the PICTURE property and the bottom row showing the image created with the MASK property.

Is there a way to combine these to properties, or to save the image as a gif or other image type, which can then be assigned to the PICTURE property of an image control or a command button?
Answer
Answer

See the following page of fellow MVP Ron de Bruin's website

http://www.rondebruin.nl/win/s2/win003.htm

and down load the Excel 2007 Version under the heading "Find the Control, Group and Tab names"

Hope this helps,
Doug Robbins - MVP Office Apps & Services (Word)
dougrobbinsmvp@gmail.com
It's time to replace ‘Diversity, Equity & Inclusion’ with ‘Excellence, Opportunity & Civility’ - V Ramaswamy

Was this reply helpful?

Sorry this didn't help.

Great! Thanks for your feedback.

How satisfied are you with this reply?

Thanks for your feedback, it helps us improve the site.

How satisfied are you with this reply?

Thanks for your feedback.

 
 

Question Info


Last updated October 5, 2021 Views 350 Applies to: