Alpha colors in controls
Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Controls
Forum Description: Topics Related to Codejock Controls
URL: http://forum.codejock.com/forum_posts.asp?TID=18167
Printed Date: 19 September 2024 at 4:45am Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com
Topic: Alpha colors in controls
Posted By: ddebono
Subject: Alpha colors in controls
Date Posted: 05 April 2011 at 2:39pm
Hi!
We are trying to use icons (.ico/.png) with alpha colors in VB6.
We are using the Pushbutton control, and the ImageManager control.
Code:
Set cmdSupport.Picture = ImageManager1.Icons.GetImage(1, 48).CreatePicture(xtpImageNormal)
The picture on the PushButton will be the icon, but with a black background instead on a transparent. The same thing with both .ico and .png files.
We know that the .ico file is working since we have tested it on the Windows 7 desktop. And the ImageManager shows them with transparent background.
It works with 24 bit icons, but not with alpha.
Is this supposed to work ? And will alpha work on the commandbar ?
We are using version 12.0.1 and upgrading the control is NOT an option.
Please help,
David
|
Replies:
Posted By: jpbro
Date Posted: 05 April 2011 at 2:55pm
Try this instead:
Set Me.cmdSupport.Icon = ImageManager1.Icons.GetImage(1, 48)
|
I haven't tested with 12.0.1 though, so I don't know if alpha is supported with that version.
------------- Product: Xtreme SuitePro (ActiveX) version 16.2.6 Platform: Windows XP - SP3
Language: Visual Basic 6.0 SP6
|
Posted By: ddebono
Date Posted: 05 April 2011 at 6:37pm
Hi!
It worked like a charm!
Thanks...
|
Posted By: jpbro
Date Posted: 05 April 2011 at 10:44pm
Great! Glad to help.
------------- Product: Xtreme SuitePro (ActiveX) version 16.2.6 Platform: Windows XP - SP3
Language: Visual Basic 6.0 SP6
|
|