Hi,
I am getting some Icons from the Shell32.dll. Althought some of the icons don't appear to be available, and I can't understand why.
I am getting the icon by loading the library by calling:
[DllImport("kernel32.dll")]
static extern IntPtr LoadLibrary(string Library);
and then getting the icon by calling:
[DllImport("User32.dll")]
public static extern IntPtr LoadImage(IntPtr ptr, int intId, uint intType, int iconWidth, int iconHeight, int loadIcon);
I send in the icon index of the icon that I am getting, which works fine for icpons such as the Open Folder Icon (index 5) and LogIn icon (Index 45) but when i try and get icons at index (71, 73, 127, etc. etc.) I get the following exception: Win32 handle that was passed to Icon is not valid or is the wrong type
I was wondering if anyone knew why this was happening? and why some of the icons are accessible and others appear not.
Thanks