I am developing a COM Add-in using VB.NET in Visual Studio 2008 Pro for Outlook 2003 and am having trouble assigning images to custom toolbar buttons.
In a nutshell, I am having to convert from an Icon type to a stdole.IPictureDisp type so that I can assign my buttons a picture.
The picture displays, but it loses the Alpha channel and the background is no longer transparent. I can verify that before the conversion to IPictureDisp object, that the PixelFormat property is set to Format32bppArgb (2498570). I am using a coding technique suggested here: http://msdn.microsoft.com/en-us/library/ms268747%28VS.80%29.aspx.
For C# users, this link blogs.msdn.com/andreww/archive/2007/10/10/preserving-the-alpha-channel-when-converting-images.aspx (sorry I am newbie and can't post more than one link! Dumb rule BTW) shows how to modify the IPictureDisp one pixel at a time and rebuild the transparency, but I can't find similar functions in VB.NET...
I would appreciate any advice regarding this. Thanks.