tags:

views:

180

answers:

2

We use wix to create setups for our application. For the case where the user has already installed an older version of our application, we do a major upgrade by making use of Upgrade elements and RemoveExistingProducts as described here. This is all working as desired: if an older version is installed, it is upgraded transparently. If a newer version is present, the installer aborts with a clear message.

However, I now want to change the InstallScope from "perUser" to "perMachine". Unfortunately this breaks the upgrade logic. The new installer does not appear to detect and remove the previous "perUser" installation. Instead, it just installs itself on top of the older version in the same ProgramFiles location. The user gets to see two entries in the "add/remove programs" list and sees two identical shortcuts on the desktop (the old user-specific one and the new perMachine one).

How do I transition my installer from the "perUser" to the "perMachine" install scope without breaking the upgrade logic?

+2  A: 

Sadly, the Windows Installer doesn't support that. Some process outside your package (a bootstrapper/chainer?) will have to manage the upgrade from per-user to per-machine.

Rob Mensching
+1  A: 

You can use this technique to detect per-user installation from per-machine install: http://www.mail-archive.com/[email protected]/msg35197.html

+1 interesting hack. That mailing list thread doesn't have confirmation that it would actually work though. I'm no longer concerned with this issue, so I can't test it quickly. If anyone can confirm that it works, please comment.
Wim Coenen