Ehsan Toghian
Ehsan Toghian

Reputation: 548

Load unistall icon from exe file in the inno setup

I have all of my icons in my executable file. If I want to change the uninstall icon of my program which is shown in Start Menu, I can easily do that by:

[Files]
Source: "icons\uninstall.ico"; DestDir: "{app}\Icons"

[Icons]
Name: "{group}\{cm:UninstallProgram,{#MyAppName}}"; Filename: "{uninstallexe}"; IconFilename: "{app}\Icons\Uninstall.ico"

Since I have Unistall.ico in my exe file, I want load the icon from it, but the below line doesn't do that and causes no icon is displayed in the Start Menu > My Program Folder

[Icons]
Name: "{group}\{cm:UninstallProgram,{#MyAppName}}"; Filename: "{uninstallexe}"; IconFilename: "{app}\{#MyAppExeName},5"

Whats wrong? Thanks

Upvotes: 2

Views: 203

Answers (1)

Miral
Miral

Reputation: 13095

",5" is not a valid part of the filename. Replace it with this:

IconFilename: {app}\{#MyAppExeName}; IconIndex: 5

(Assuming of course that you do have at least 6 icon resources in your application.)

Upvotes: 0

Related Questions