cam2009
27th September 2010 16:58 UTC
Uninstalling Shortcuts for 32/64 bit
Hello
During installation user selects 32 or 64 bit installation. Installer sets a variable: "32_or_64_bit"
When I uninstall shortcuts I also use this variable:
${If} $32_or_64_bit == "32bit"
Call un.Remove_Shortcuts_32
${Endif}
${If} $32_or_64_bit == "64bit"
Call un.Remove_Shortcuts_64
${Endif}
The problem is that this variable is not set for uninstaller.
1) Is it possible to set/save this variable in the uninstaller?
2) how do I determine that it is a 32 or 64 bit uninstaller based on "32_or_64_bit" that was set in installer?
Thank you
Animaether
27th September 2010 18:01 UTC
A. Store the value of the variable in the registry on installation, then on uninstallation read that value from the registry?
B. If your installer can install both 32bit and 64bit, and the possibility may occur that a user has both installed at the same time, then there are a few options.. the most robust, if you can't rely on environment data (i.e. $PROGRAMFILES vs $PROGRAMFILES64), would be store a file along with the uninstaller that the uninstaller can then check to see if's supposed to uninstall 32bit or 64bit.
An alternative is with command-line flags, but if a user browses to your uninstaller manually and launches the uninstaller, the uninstaller may not know which of the two it's supposed to uninstall.