The MASM Forum

General => The Campus => Topic started by: Villuy on January 13, 2025, 07:04:11 PM

Title: Problem with .ico
Post by: Villuy on January 13, 2025, 07:04:11 PM
I try to add icon to .res file:

https://www.iconfinder.com/icons/17558/document_icon (https://www.iconfinder.com/icons/17558/document_icon)

MASM gives an error:

error RC2176: old DIB in MyIcon.ico; pass it through SDKPAINT

Some files are ok, but most are like this. Apparently MASM not understands modern .ico file formats.
Title: Re: Problem with .ico
Post by: jj2007 on January 13, 2025, 09:18:35 PM
They look nice, no doubt, but they are in *.png format...
Title: Re: Problem with .ico
Post by: Villuy on January 13, 2025, 10:00:10 PM
Quote from: jj2007 on January 13, 2025, 09:18:35 PMThey look nice, no doubt, but they are in *.png format...

There are two buttons: | PNG | Other |

This author has whole gallery of masterpieces, yes:

https://www.iconfinder.com/iconsets/packyuuyake (https://www.iconfinder.com/iconsets/packyuuyake)
Title: Re: Problem with .ico
Post by: Villuy on January 13, 2025, 11:47:26 PM
I have bypassed problem by using rc.exe from Microsoft SDK.
Title: Re: Problem with .ico
Post by: HSE on January 14, 2025, 12:03:05 AM
Hi Villuy,

Quote from: Villuy on January 13, 2025, 07:04:11 PMMASM gives an error:

Look like RC.exe error. What version you have? (and what ml.exe?)  :biggrin: That was.

Quote from: jj2007 on January 13, 2025, 09:18:35 PMThey look nice, no doubt, but they are in *.png format...

Very interesting, I don't know that. New .ico versions can be .png inside, with a little diferent file header  :thumbsup:

HSE