David S. Anderson

I have created a Class Library project to store my icons needed for my solution. These icons need to be used by a Setup & Deployment project so my custom file types can get their icons from this dll.

In my dll I have created a default resource file and added the icons. I have changed the icons to "embedded resources". However, I still cannot access these resources from the dll.

Basically, these icons should be accessible just as the icons are in Shell32.dll.

Re: Windows Forms General Problem working with a resource dll.


I know you program in C++. The C++ IDE doesn't have good support for managed resources but (I think) it will let you embed a resource in the assembly metadata. Once in there, it is pretty much locked to non-managed setup programs, they wouldn't have any idea how to serialize the metadata stream back to an Icon. It would take a call to Assembly.GetManifestResourceStream().

What you probably need for what you want to do is a native Windows icon resource, not a managed resource. You've got the resource editor in the C++ IDE to put one in. That's how shell32.dll does it.

Re: Windows Forms General Problem working with a resource dll.

Ðãv? S. Â???????

Edit: I've created the Win32 DLL and have added my icons via the Resource Editor and now it works. Thank you very much nobugz!