I agree, but haven't I done the Workaround method 2 by this:

 

<InstallExecuteSequence>
<Custom Action=3D'NoDowngrade'
After=3D'FindRelatedProducts'>NEWERPRODUCTFOUND</Custom>
<RemoveExistingProducts After=3D"InstallInitialize" />
</InstallExecuteSequence>

 

Sounds like this:=20

=20

http://support.microsoft.com/kb/905238/en-us=20

=20

Phil Wilson=20

=20

From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Darren
Thomas
Sent: Friday, November 16, 2007 10:51 AM
To: [EMAIL PROTECTED]
Subject: [WiX-users] RemoveExistingProducts .NET GAC'd Assemblies
Removed

=20

All,

I've written a very simple Wix Script to install an exe (notepad in this
case) and a signed .Net dll to the GAC. This seems to work just fine.
However I want to test an upgrade. I would like the previous version to
be uninstalled and then the new version installed. I don't watch to
patch because I don't want to keep track of what changes occur in the
MSI. So the safest thing for me to do is a complete re-install.

To do this I change the version number from 1.0 to 1.1 and the upgrade
version from 1.0 to 1.1 in the script below, I then compile the script
and run it. My assembly MyCommon.dll is then removed from the GAC???
I've read that I need to increment the assembly version number etc, but
in a larger script one of my dll's may not change but I would still like
to have it re-deployed.

What am I doing wrong? I've even tried changing the sequence to move
RemoveExistingProducts to an earlier place. This works but I don't
think it's the correct thing to do as Orca moans about it...

Do I need to use the REINSTALL=3DALL switch? if so why? =20


<?xml version=3D"1.0" encoding=3D"windows-1252"?>

<Wix xmlns=3D"http://schemas.microsoft.com/wix/2003/01/wi
<http://schemas.microsoft.com/wix/2003/01/wi
<http://schemas.microsoft.com/wix/2003/01/wi%3e> > ">

<Product Name=3D"Sample Application"=20
Id=3D"????????-????-????-????-????????????" =20
Language=3D"1033"=20
Codepage=3D"1252"=20
Version=3D"1.0"=20
Manufacturer=3D"ACME"=20
UpgradeCode=3D"74b8b879-c395-423b-a289-b1e369837f1d" >
=20
<Package Id=3D"????????-????-????-????-????????????"=20
Keywords=3D"Installer"=20
Description=3D"Sample Application"=20
Manufacturer=3D"ACME."=20
InstallerVersion=3D"200"
Languages=3D"2057"=20
Compressed=3D"yes"=20
SummaryCodepage=3D"1252"/>
=20
<Media Id=3D"1" Cabinet=3D"Sample.cab" EmbedCab=3D"yes"/>
=20
<Upgrade Id=3D"74b8b879-c395-423b-a289-b1e369837f1d">
<UpgradeVersion OnlyDetect=3D"yes" Property=3D"NEWERPRODUCTFOUND"
Minimum=3D"1.0" IncludeMinimum=3D"no" />
<Property Id=3D"NEWERPRODUCTFOUND" Secure=3D"yes" />
<UpgradeVersion OnlyDetect=3D"no" =
Property=3D"PREVIOUSVERSIONSINSTALLED"
IncludeMaximum=3D"no" Maximum=3D"1.0" />
<Property Id=3D"PREVIOUSVERSIONSINSTALLED" Secure=3D"yes" />
</Upgrade>
=20
<CustomAction Id=3D'NoDowngrade' Error=3D'A later version of Sample is
already installed.' />
=20
<Directory Id=3D"TARGETDIR" Name=3D"SourceDir">
<Directory Id=3D"ProgramFilesFolder" Name=3D"PFiles">
<Directory Id=3D"Sample" Name=3D"Samp">
<Directory Id=3D"INSTALLDIR" Name=3D"Test">
<Component Id=3D"Sample.Component"
Guid=3D"56fba829-1f49-4fa5-a4bd-6f136d38eed9" DiskId=3D"1">
<File Id=3D"Sample.File" Name=3D"Notepad.exe" =
LongName=3D"Notepad.exe"
src=3D"Notepad2.exe" KeyPath=3D"yes"/>
</Component>
<Component Id=3D"Common.Component"
Guid=3D"9063055d-ead2-4310-8fc5-f5cfc64cd4c7" DiskId=3D"1">
<File Id=3D"Common.File" Name=3D"MyCom.dll" Assembly=3D".net"
LongName=3D"MyCommon.dll" src=3D"MyCommon.dll" KeyPath=3D"yes"/>
</Component>
</Directory>
</Directory>
</Directory>
</Directory>
<Feature Id=3D"Complete"=20
Title=3D"Sample"=20
Description=3D"Complete"=20
TypicalDefault=3D"install"=20
Display=3D"expand"=20
Level=3D"1"=20
ConfigurableDirectory=3D"INSTALLDIR">
<ComponentRef Id=3D"Sample.Component"/>
<ComponentRef Id=3D"Common.Component"/>
</Feature>

<InstallExecuteSequence>
<Custom Action=3D'NoDowngrade'
After=3D'FindRelatedProducts'>NEWERPRODUCTFOUND</Custom>
<RemoveExistingProducts After=3D"InstallInitialize" />
</InstallExecuteSequence>
=20
</Product>
</Wix>

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to