473,412 Members | 2,067 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,412 software developers and data experts.

Transparent Color in an Icon

How can I find the transparent color in an Icon and convert it into a Color
type in VB.Net 2003?

I want to convert it into a bitmap with the same color transparent. I know
that I can convert it to a bitmap then read the color of the pixel at 0,0
then make that color transparent in the bitmap but this doesn't work on icons
that have other than the transparent color in the 0,0 pixel position.

--
Dennis in Houston
Nov 21 '05 #1
8 5619
Dennis,

Bob Powell is the painting guy, did you see his pages already

http://www.bobpowell.net/

I hope this helps something

Cor
Nov 21 '05 #2
Thanks but he doesn't cover this topic.
--
Dennis in Houston
"Cor Ligthert" wrote:
Dennis,

Bob Powell is the painting guy, did you see his pages already

http://www.bobpowell.net/

I hope this helps something

Cor

Nov 21 '05 #3
Dennis,

I see now that your question is not often answered in this newsgroup.

However maybe you can search this newsgroup and first look at this thread,

http://groups-beta.google.com/group/...26cb411e73a2c8
:-)

Cor
Nov 21 '05 #4
:-) lovely site! it isn't?

Cor Ligthert wrote:
Dennis,

Bob Powell is the painting guy, did you see his pages already

http://www.bobpowell.net/

I hope this helps something

Cor

Nov 21 '05 #5
"Dennis" <De****@discussions.microsoft.com> schrieb:
How can I find the transparent color in an Icon and convert it into a
Color
type in VB.Net 2003?

I want to convert it into a bitmap with the same color transparent. I
know
that I can convert it to a bitmap then read the color of the pixel at 0,0
then make that color transparent in the bitmap but this doesn't work on
icons
that have other than the transparent color in the 0,0 pixel position.


Did you already try 'ToBitmap'? This method will preserve transparency:

\\\
Dim i As Icon = ...
Dim b As Bitmap = i.ToBitmap()
///

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Nov 21 '05 #6
Haven't tried that yet but will do so. When it's converted to the bitmap, is
there any way to find the transparency color from the bitmap?
--
Dennis in Houston
"Herfried K. Wagner [MVP]" wrote:
"Dennis" <De****@discussions.microsoft.com> schrieb:
How can I find the transparent color in an Icon and convert it into a
Color
type in VB.Net 2003?

I want to convert it into a bitmap with the same color transparent. I
know
that I can convert it to a bitmap then read the color of the pixel at 0,0
then make that color transparent in the bitmap but this doesn't work on
icons
that have other than the transparent color in the 0,0 pixel position.


Did you already try 'ToBitmap'? This method will preserve transparency:

\\\
Dim i As Icon = ...
Dim b As Bitmap = i.ToBitmap()
///

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Nov 21 '05 #7
Well, bitmaps really can't have transparent colors... I would
personally use PNGs. And even then, Microsoft is notorious for making
it almost impossible to use ARGB in .Net.

Nov 21 '05 #8
So how does bitmap.MakeTransparent(color.red) work. Doesn't the bit map
display routines mask all pixel colors with Red backgroud mask that is Xor'd
or something like that to cancel out displaying all red colors in the bitmap.
I'm looking to find what that color is...there must be someway since the
bitmap certainly can have transparent areas.
--
Dennis in Houston
"ba*******@gmail.com" wrote:
Well, bitmaps really can't have transparent colors... I would
personally use PNGs. And even then, Microsoft is notorious for making
it almost impossible to use ARGB in .Net.

Nov 21 '05 #9

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Martin Reikenkamp | last post by:
I'd like to use a transparent icon in a ms access form. The icon looks good (transparency) when I use the Windows XP-style. But when I switch the preferences of the Windows & Buttons-settings to...
0
by: Ziver | last post by:
Hello, I used the utility "Easy Icon Maker" and created a transparent icon for my Outlook button. When i view it from the windows explorer i see as transparent but if i execute my add-in that...
2
by: Peter Steele | last post by:
Visual Studio provides an icon editor but I can't figure out how to create a transparent icon. My app always shows the full 32x32 square, with a wide background instead of a transparent one. How do...
0
by: Josch | last post by:
I have here a specific problem with ASP.NET in C#. I want to convert an Icon (System.Drawing.Icon icon) to a GIF-Image. First, my attempt was converting the icon to a Bitmap: Bitmap bmp =...
0
by: FredC | last post by:
I'm using VS C#.Net 2003. I built a simple windows form app. with the following attributes: - has a BackgroundImage set to a jpeg I built a very simple user control that contains a picture box set...
1
by: FredC | last post by:
I'm using VS 2003, C#.Net 2003. I built a simple windows form app. with the following attributes: - has a BackgroundImage set to a jpeg I built a very simple user control that contains a...
2
by: Lee | last post by:
Hi, I have a notify icon and have been trying to make the background color transparent. But do .ico files allow a transparent color? when i select the image for the notify icon it askes for...
1
by: =?Utf-8?B?a2VpdGguaHV0Y2hpc29u?= | last post by:
G'day Any tips on how to make a transparent icon for a vb.net application. I'm using Visual Studio 2005. Thanks
3
vdraceil
by: vdraceil | last post by:
Does anyone know hw to set the background icon text color(in win XP) to transparent?? I accidently changed it to some color and now it is possible to change to any other color,but not...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.