Article ID: 822488 - Last Review: May 16, 2007 - Revision: 1.5 BUG: The icon that is displayed on the control loses the alpha channel when you set the Image property of a Microsoft Windows Form control to a 32-bit alpha-blended iconOn This PageSYMPTOMSWhen you set the Image property of a Microsoft Windows Form (Winform) control to a
32-bit alpha-blended icon, the icon that is displayed on the control loses the
alpha channel. The transparent regions of the icon are rendered as solid. This
behavior occurs at design time and at run time for the Winform
control. WORKAROUNDTo work around this bug, override the Paint event handler for the Winform control, and then call the DrawIcon method. To do this, follow these steps. Note These steps are based on the "Steps to Reproduce the Behavior" section of this article.
STATUS
Microsoft has confirmed that this is a bug in the Microsoft products that are
listed at the beginning of this article.
MORE INFORMATIONSteps to Reproduce the Behavior
REFERENCESFor more information about the DrawIcon method, visit the following Microsoft Developer Network (MSDN)
Web site: http://msdn2.microsoft.com/en-us/library/system.drawing.graphics.drawicon(vs.71).aspx
(http://msdn2.microsoft.com/en-us/library/system.drawing.graphics.drawicon(vs.71).aspx)
For more information about the Paint event, visit the following MSDN Web site:http://msdn2.microsoft.com/en-us/library/system.windows.forms.control.paint(vs.71).aspx
(http://msdn2.microsoft.com/en-us/library/system.windows.forms.control.paint(vs.71).aspx)
APPLIES TO
| Article Translations
|

Back to the top
