Click here to Skip to main content
15,891,607 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Can anybody please help me with a code sample or a solution to overlay icons in C#.Net?

Thanks in Advance.

here are few screen shots of the way i want it to be.
http://www.imageuploading.net/images/11044/picture-with-new-folders
http://www.imageuploading.net/images/11043/snapshot-with-new-files-2cnew-folders-and-one-old-folder
Posted
Updated 29-May-11 20:40pm
v8
Comments
OriginalGriff 20-May-11 2:19am    
What have you tried?
Google?
Anything yourself?
freakosandy 20-May-11 2:21am    
i found a solution in c++, but i need it in C#. you have any solutions?? tried googling a lot. no luck :(
freakosandy 20-May-11 2:22am    
also i found a COM coding in C# but then i have no idea of coding in COM :(
Dalek Dave 20-May-11 3:22am    
Edited for Grammar.

See this for creating shell overlay icons in .NET:

.NET Shell Extensions - Shell Icon Overlay Handers[^]
 
Share this answer
 
Comments
fjdiewornncalwe 13-Feb-13 16:01pm    
Shameless advertising for your article... :) +5 even though it's a very old question... Cheers.
Dave Kerr 14-Feb-13 3:26am    
Of course! But I think the project is useful and will be helpful for those looking over this question in the future :)
You don't need icons. Icons are special multi-page resources which contain images of different resolution in the same file, typically 16x16 and 32x32. This is needed for collaboration with Windows and Shell. In applications, icons are only uses as application icons (so the application is shown correctly in the system tray and file managers/dialogs) and windows icons. With icons, OS selects the image of appropriate resolution. If you use icons anywhere else, their properties would be redundant. Technically, you can use them, but there is not reason for doing that.

For all other cases, bitmaps should be used. Icons also support transparent colors, but so do bitmaps if you store them as PNG.

There is no problem of overlay them. You can use bitmaps in control rendering using System.Drawing.Graphics.DrawImage or System.Windows.Forms.PictureBox.

—SA
 
Share this answer
 
Comments
freakosandy 20-May-11 2:52am    
Your answer
sorry i was not clear in my question. my project should do something like this. for example.i add a new folder or file(willl handle it internally whether the file is new or old). now when the file is new.i wan a green tick mark on that particular file or folder(tick marks is another .ico file).
Sergey Alexandrovich Kryukov 20-May-11 3:20am    
Still not clear. Can you reflect other people thoughts? Imagine someone explains this to you. Would you understand it?
--SA
freakosandy 20-May-11 3:27am    
ok i will post a screenshot and explain it to you
freakosandy 20-May-11 4:38am    
i've updated the question. please go through it
Sergey Alexandrovich Kryukov 20-May-11 23:24pm    
OK, I guess I see what do you mean, so: do you need to extract icons from the applications? Why you're interested in overlay?
--SA
 
Share this answer
 
Comments
freakosandy 20-May-11 3:29am    
i need it in c# ram :(
icon overlay sample code shows in this link
icon overlay[^]
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900