icon.save 16x16

  • Thread starter Thread starter Jo Franklin
  • Start date Start date
J

Jo Franklin

I am using icon.save to save icon files I've extracted using ExtractIconEx.
when I save the large icon everything is fine, but when I save the small
icon it looks distorted, and has a black (not transparent) background. Any
ideas why?
 
* "Jo Franklin said:
I am using icon.save to save icon files I've extracted using ExtractIconEx.
when I save the large icon everything is fine, but when I save the small
icon it looks distorted, and has a black (not transparent) background. Any
ideas why?

That's hard to say without seeing any code...
 
ExtractIconEx(sFile, 17, IconPtrLarge, IconPtrSmall, 1)

myIcon = Icon.FromHandle(IconPtrLarge)


Dim iconFile As New IO.FileStream("C:\icon2.ico", FileMode.OpenOrCreate)

myIcon.Save(iconFile)

iconFile.Close()

myIcon.Dispose()

This code works fine. The 32x32 icon is saved properly, but if I change the
line to: myIcon = Icon.FromHandle(IconPtrSmall) - to get the 16x16 icon Then
save the file it has that black background and looks somewhat distorted.
 
Back
Top