Using Package/@Id="*" I'm using the following code - this prevents two versions being installed where only the 4th version number differs. This is primarily to prevent confusion with internal testing, and means that we bump the third version following each public release in order to permit upgrades. We only release major upgrades, so I've got no idea how the code below would perform in a minor upgrade/patch scenario.
<Upgrade Id="$(var.Property_UpgradeCode)"> <UpgradeVersion OnlyDetect="yes" Minimum="$(var.version)" Property="NEWERVERSIONDETECTED" IncludeMinimum="no" /> <UpgradeVersion OnlyDetect="no" Maximum="$(var.version)" Property="OLDERVERSIONBEINGUPGRADED" IncludeMaximum="no" /> <!-- Detect for changes in 4th field only --> <UpgradeVersion Property="ANOTHERBUILDINSTALLED" Maximum="$(var.version)" Minimum="$(var.version)" IncludeMinimum="yes" IncludeMaximum="yes" OnlyDetect="yes" /> </Upgrade> <CustomAction Id="CA_BlockOlderVersionInstall" Error="!(loc.LaunchCondition_LaterVersion)" /> <CustomAction Id="CA_BlockAnotherBuildInstall" Error="!(loc.LaunchCondition_AnotherBuild)" /> <InstallExecuteSequence> <Custom Action="CA_BlockOlderVersionInstall" After="FindRelatedProducts"> <![CDATA[NEWERVERSIONDETECTED]]> </Custom> <!-- Prevent installation on 4th version field change only --> <Custom Action="CA_BlockAnotherBuildInstall" After="FindRelatedProducts"> <![CDATA[ANOTHERBUILDINSTALLED]]> </Custom> </InstallExecuteSequence> On Mon, Dec 7, 2009 at 5:54 PM, Asker Brodersen <asker.broder...@esri-sgroup.se> wrote: > Giora, do your versions differ by more than the fourth digit? > > I have found that if you install 1.0.0.0 and then 1.0.0.1 they will both be > listed as installed. > Incrementing the third digit (ie 1.0.0.0 to 1.0.1.0) the older version will > be replaced. > To enable replacement also by fourth digit version increments, this is how my > Upgrade section looks like (Id for both Product and Package are '*', and my > current build version is '$(var.BuildVersion)'): > > <Upgrade Id='YOUR-OWN-GUID-HERE'> > <!-- Define the range of old versions that should be upgraded by the new > .msi --> > <!-- IncludeMaximum='yes' gives ICE61 warning as it forces upgrade of same > version installs, > but is neccesary to upgrade versions that differ by only the fourth digit ie > 1.0.0.0 to 1.0.0.1. > Normally only 1.0.0.0 to 1.0.1.0 differences are treated as a new version--> > <UpgradeVersion OnlyDetect='no' > Maximum='$(var.BuildVersion)' > Property='OLDERVERSIONBEINGUPGRADED' > IncludeMaximum='yes' /> > > <!-- Detect out-of-order installations --> > <UpgradeVersion OnlyDetect='yes' > Minimum='$(var.BuildVersion)' > Property='NEWERVERSIONDETECTED' > IncludeMinimum='no' /> > </Upgrade> > > Regards, > Asker > > -----Original Message----- > From: Neil Sleightholm [mailto:n...@x2systems.com] > Sent: den 6 december 2009 18:46 > To: General discussion for Windows Installer XML toolset. > Subject: Re: [WiX-users] multiple entries in add remove programs. > > 1. Package/@Id is optional but "*" is ok. > 2. Order doesn't matter > 3. Not sure I understand > > Is your UpgradeCode/@Id fixed for both installations? Do you have > RemoveExistingProducts scheduled somewhere? Do you have an <Upgrade> > section? > > You shouldn't need to update using that command line, it should just > work when you run it. > > I hope that helps. > > Neil > > -----Original Message----- > From: Giora keinan [mailto:grkei...@gmail.com] > Sent: 06 December 2009 15:29 > To: General discussion for Windows Installer XML toolset. > Subject: Re: [WiX-users] multiple entries in add remove programs. > > Neil Hello > Thanks for the fast answer. > I looked at code in the URL you sent me. It looks for me that my code > is similar. > > The differences I found where: > 1. My code has <Package Id='*' Keywords='Installer' > which is not in the code you sent me. > 2. In my code the order of <Product Name='CapsCake' Id='*' is reversed > to the one in your code "<Product Id="*" Name=xxxx > 3. I have code for founding the original installation directory. > > What I failed to find is what make the installer to add one more entry > to the add / remove programs. > > As the upgrade command I am using: > > msiexec /i "CapsCakeUpgrade.msi" REINSTALLMODE=omu > > Thanks > Giora > > > > Neil Sleightholm wrote: >> It sounds like you haven't got the upgrade code correct, there is a >> sample here >> > http://neilsleightholm.blogspot.com/2009/01/wix-script-for-major-upgrade >> s.html that might help. >> >> Neil >> >> -----Original Message----- >> From: Giora Keinan [mailto:grkei...@gmail.com] >> Sent: 06 December 2009 12:54 >> To: wix-users@lists.sourceforge.net >> Subject: [WiX-users] multiple entries in add remove programs. >> >> hello >> Each time I am running a new upgrade, the installer add one more entry > >> in the add remove program. >> How can I made an upgrade without adding it to the add remove program >> (leaving only one add remove in place). >> >> Thanks >> Giora >> >> > > -- > ------------------------------------------------- > Giora Keinan > CapsCake - The natural language launcher. > Because free text is easy. > http://www.capscake.com > ------------------------------------------------- > > > ------------------------------------------------------------------------ > ------ > Join us December 9, 2009 for the Red Hat Virtual Experience, > a free event focused on virtualization and cloud computing. > Attend in-depth sessions from your desk. Your couch. Anywhere. > http://p.sf.net/sfu/redhat-sfdev2dev > _______________________________________________ > WiX-users mailing list > WiX-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/wix-users > > ------------------------------------------------------------------------------ > Join us December 9, 2009 for the Red Hat Virtual Experience, > a free event focused on virtualization and cloud computing. > Attend in-depth sessions from your desk. Your couch. Anywhere. > http://p.sf.net/sfu/redhat-sfdev2dev > _______________________________________________ > WiX-users mailing list > WiX-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/wix-users > > ------------------------------------------------------------------------------ > Join us December 9, 2009 for the Red Hat Virtual Experience, > a free event focused on virtualization and cloud computing. > Attend in-depth sessions from your desk. Your couch. Anywhere. > http://p.sf.net/sfu/redhat-sfdev2dev > _______________________________________________ > WiX-users mailing list > WiX-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/wix-users > ------------------------------------------------------------------------------ Join us December 9, 2009 for the Red Hat Virtual Experience, a free event focused on virtualization and cloud computing. Attend in-depth sessions from your desk. Your couch. Anywhere. http://p.sf.net/sfu/redhat-sfdev2dev _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users