View Single Post
  #2  
Old 07-01-2020, 19:04
Cesar82's Avatar
Cesar82 Cesar82 is offline
Registered User
 
Join Date: May 2011
Location: Brazil
Posts: 1,074
Thanks: 1,814
Thanked 2,304 Times in 787 Posts
Cesar82 is on a distinguished road
Quote:
Originally Posted by Proxson View Post
*knock...knock...anybody home ?

Edit: Ok, I got the Registry "issue" under control. It's not an elegant solution but it works. Till someone finds something better.

Code:
#define AppPublisher "SEGA"
Code:
   { remove product code registry entrie }
    if ProductCode <> '' then
      RegDeleteKeyIncludingSubkeys(HKLM, 'SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\' + ProductCode);
      RegDeleteKeyIncludingSubkeys(HKLM, 'SOFTWARE\{#AppPublisher}');
  end;
end;
Eh, now the Start Menu shortcuts...
You have greatly altered the original CIU script.
There will be some bugs with these changes.
The About page has stopped working.
You can change the script for your use, but I ask you to keep the About page working and original by displaying the credits of the original CIU contributors and translators.

Answering your question:
CIU does not create an uninstaller as in conventional Inno Setup installers (Unis000.exe, Unis000.dat).
Uninstall.exe from the installation folder is the same Setup.exe file that is copied to the folder and the uninstall functions are all defined in the code section.
Therefore the installer does not remove icons included in the [Icons] section, so you must include them in the code within the CreateShortcuts and DeleteShortcuts functions.
The [UninstallDelete] section is also not supported on CIU as the default uninstallation of Inno Setup is never performed.
You can include the functions of deleting folders or files within the Uninstall function of code.

NOTES:
You have removed almost all languages, this can cause errors.
I would not recommend these changes all in the script the way you did.
You could simply have limited the languages ​​you want to make available in Setup.ini or disabled the lines in the [Files] section and changed only in GetLanguage and also the part in CheckAvaiLanguages ​​where you changed to:
if (TmpStr2 in ['HR', 'ENUK', 'EN']) then
Reply With Quote
The Following 2 Users Say Thank You to Cesar82 For This Useful Post:
devil777 (12-01-2020), Grumpy (08-01-2020)