views:

1518

answers:

1

Hi all,

I have an installer of an application that needs to install over any existing version, regardless of version number.

Instead, I've got an installer that constantly says that I need to go to add/remove programs. That's very frustrating behavior for my testers, since it just slows them down for no real reason in their minds-- the previous installer package would always just install, deleting any files that were previously there, so they never had to do that step. We also have a (large) customer base that's been similarly trained, in that whatever version I install right now should overwrite whatever install I might have had before.

It seems, from what I can gather, that the WiX paradigm is to do things like block backwards version installations and other complicated things, like patching. Our customers, frankly, are not smart enough to know or care about patching, merging, whatever, and just want one installer that always works (and I'm inclined to agree with them; the bandwidth is cheap). So how do I get that?

I've tried this, but it just doesn't seem to matter:

<InstallExecuteSequence>
  <RemoveExistingProducts Before="InstallInitialize"/>
</InstallExecuteSequence>

This is version 3.0.5120 of WiX.

EDIT: As per Rob's suggestion there, I've added this code:

<InstallExecuteSequence>
  <RemoveExistingProducts After="InstallInitialize"/>
</InstallExecuteSequence>

<Upgrade Id="27cb76c7-544e-465f-b1f3-b11d9a49e416">
  <UpgradeVersion Minimum="0.8.0"
                  IncludeMinimum="yes"
                  Maximum="1.5.1"
                  Property="OLDERVERSIONBEINGUPGRADED" />
</Upgrade>

I'm not adding the code to not allow for a rollback installation; for reasons that are incredibly embarrassing to me, let's just say that an increase in version number does not necessarily correlate to an increase in software goodness. I don't want anyone to get locked out of what they think they need.

Also, very important, is to change the default GUID for the product to "*" in order to make for a different GUID with a different installer, which was apparently the problem.

+5  A: 

You want a major upgrade. There is a topic dedicated to that in the WiX.chm "How To" (also on the web: http://wix.sourceforge.net/manual-wix3/major_upgrade.htm).

Rob Mensching
Looking interesting. So if I just want the upgrading stuff, but I also want to allow going back a version, then I just leave out the second part about not allowing lower version installations, I'm thinkin'.
mmr