Possible duplicate:
How to extract a specific image from an icon file in .NET?
I have a file "multi.ico" that has four images of different sizes (16x16, 24x24, 32x32, 48x48). Each image size is different in color to make it easier to determine what size we are dealing with. This file has been pasted into the Multi.resources resource file using the Lutz Roeder.NET Resourcer.
I need to be able to extract ico from a .resource file in such a way as to save all four image sizes. Ideally, I would like to have a wrapper class around an .ico object that allows me to select an image of the appropriate size.
I have a working shell that I can use with a standalone .ico file (multi.ico), but there are a lot of images on my company system and we need to be able to link them with .resource files for distribution.
Can someone show me a piece of code that takes the .resources file, will extract the 16x16 version of the embedded .ico file. I do not seem to see anything but a 32x32 image.
source
share