Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to do major upgrades when using burn / WiX 3.6

Tags:

wix

wix3.6

I have one MSI setup like this:

<Product Id="*" ... UpgradeCode="4207FF3B-5E0D-4311-9DFC-B41AA8DE2965" />
    <MajorUpgrade DowngradeErrorMessage="Can't downgrade" />

It works as expected:

  1. Install product
  2. Recompile (effectively generating a new Id)
  3. Starting the new msi file brings up the change view and I can repair or uninstall the product.

Good. But then comes burn.

I have created the most simplistic Bundle one can thing of. I use the standard bootrapper and just add one single MsiPackage:

<MsiPackage SourceFile="$(var.Setup.TargetPath)" />

The problem is that after each recompile I can install the product once again beside the already installed product, without changing anything! This results in duplicate ARP entries!

If I don't recompile and run the bundle exe-file twice, I get the modify setup screen as expected. What can I do to have the same behaviour with burn as I had with just an MSI?

like image 751
Daniel Lang Avatar asked Jul 20 '12 03:07

Daniel Lang


1 Answers

Increment the bundle version number and Burn will upgrade the previous version and remove it.

like image 195
Bob Arnson Avatar answered Oct 19 '22 15:10

Bob Arnson