Can I change the delete icon in Inno Setup?

From what I read, it looks like this is not a parameter that allows you to change the delete icon:

[Setup]: UninstallIconFile Description: Obsolete in 5.0.0. As Setup and Uninstall have been merged into a single executable, setting a custom icon for Uninstall is no longer possible. 

So, is there any other way to change this icon? I ask because if you only have your exe run, readme and uninstall, users can accidentally click on uninstall instead of lauch, which is a little annoying.

Thanks.

+6
uninstall inno-setup
source share
3 answers

The icon for deletion will only be the same as the icon for your application if you set the IconFilename parameter IconFilename the same icon as the application, or set the SetupIconFile parameter in the same way as your application.
By default, the Delete icon is the same as the Settings icon. If you really want to make sure that the user is not confused, you can set the IconFilename parameter in the [Icons] section to the delete icon. Something like:

 Name: "{group}\Uninstall My Program"; Filename: "{uninstallexe}"; IconFilename: "{app}\uninstall.ico" 

You will need to include uninstall.ico in your [Files] section.

+6
source share

To change the icon of the executable file for deletion, you must change the icon of the installer executable file, since it is the same exe using the SetupIconFile installation section directive.

For instance:

 SetupIconFile=MyProgSetup.ico 

You can also change the icon displayed on the control panel by setting the UninstallDisplayIcon directive

For instance:

 UninstallDisplayIcon={app}\MyProg.exe,4 ;or UninstallDisplayIcon={app}\Uninstaller.ico 
+7
source share

Set the uninstaller icon as SetupIconFile , then change the resource icon in the compiled .exe. (There are many programs for this, such as ResHacker )

If you see the compiled .exe file still with the uninstaller icon, just move that .exe to a different folder and you will notice.

+1
source share

All Articles