The 24bpp pixel format doesn't define transparency (Alpha) and so the system
automatically changes to a format that can express the transparent value.
There is no way to display a 24bpp image with transparency on a per-pixel
basis.
--
Bob Powell [MVP]
Visual C#, System.Drawing
Ramuseco Limited .NET consulting
http://www.ramuseco.com
Find great Windows Forms articles in Windows Forms Tips and Tricks
http://www.bobpowell.net/tipstricks.htm
Answer those GDI+ questions with the GDI+ FAQ
http://www.bobpowell.net/faqmain.htm
All new articles provide code in C# and VB.NET.
Subscribe to the RSS feeds provided and never miss a new article.
"Sharon" <Sh*****@newsgroups.nospam> wrote in message
news:1A**********************************@microsof t.com...
Hello Experts,
I'm creating a bitmap object like this:
Bitmap myImage = new Bitmap(1024, 1024,
System.Drawing.Imaging.PixelFormat.Format24bppRgb) ;
But when I invoking the function myImage .MakeTransparent() (with or
without
parameters), the myImage.PixelFormat changes to Format32bppArgb.
Why is that and how can I avoid it but still making the Bitmap transparent
?
----------
Thakns
Sharon