View Full Version : uninstall before install a package

12-07-2011, 06:31 PM
I want to create a custom action that uninstall a previously install package before a new installation begins. I don't want to do it from the major update feature of MSI. I want to run the command:

msiexec.exe /uninstall {xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx}

in a custom action before the MSI finds out that the package is already installed and drop my installation.

I tried Before System Search which is the earliest action you can perform but this happened after the MSI finds that the package is already installed.

Any suggestion?

Thanks in advance,


04-27-2012, 01:17 AM
the custom actions even if you sequence them before the first action they will not get executed immediately but they will be recorded and then executed so the custom actions cant be used to uninstall before the script is generated...so what ever may be sequence the product search will be done first