cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Performing a Major Upgrade with InstallScript

Performing a Major Upgrade with InstallScript

Summary

This article discusses how to perform major upgrades on installs built with an older version of InstallShield.

Synopsis

For major upgrades of older installations created with older versions of InstallShield, the best practice is to call the the cached setup.exe or .msi to uninstall itself completely before continuing with the new install. The new project should contain a completely new GUID apart from the previous version. Ideally, the name should be different as well. However, if the name is the same, then the version number should be increased accordingly.

 

Discussion

For old InstallShield installations (created with Professional 5, 6, & 7, Developer 7 & 8, DevStudio 9, or InstallShield X, 10.5), there will be a registry key in the location: HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall\ that contains either the name of the program or the GUID number in brackets. This key should contain a value called "UninstallString". This is the command line that Add/Remove Programs executes for any given installation, and location that contains the path to the setup or MSI that needs to be uninstalled.
 
Once the path to the setup is determined from the UninstallString, it can be launched using LaunchAppAndWait. If the registry key value contains a path to a .exe file, the LaunchAppAndWait can be launched with an uninstall parameter similar to the following example (which should be called early in the installation, such as in the OnBegin event handler):
 
LaunchAppAndWait ( "C:\\Program Files\InstallShield Installation Information\\{YOUROLDPRODUCTGUIDHERE}\\Setup.exe", "/uninst", LAAW_OPTION_WAIT);
 
If the old installer was an MSI-based installation, then msiexec.exe should be launched with /x and the GUID as parameters:
 
LaunchAppAndWait ( "msiexec.exe", "/x {YOUROLDPRODUCTGUIDHERE}", LAAW_OPTION_WAIT); 
 

 

Additional Information

Uninstallations can also be run silently, with no user interface. Please view the following articles for uninstalling each kind of project type. The results can also be applied through LaunchAppAndWait.
 
 
 
 
 
Was this article helpful? Yes No
No ratings
Version history
Last update:
‎Oct 04, 2022 03:25 PM
Updated by:
Contributors