The Upgrade table only comes into play when doing a major upgrade.  A minor 
upgrade is basically a 
repair with a new set of files.

Rob

Nicholls, Rob (CSS) wrote:
> Hi all,
> 
> Sorry for the horrible formatting - here goes again!
> I am new here but have searched the list and cannot find a relevant
> answer.
> 
> I am following the tutorial found at
> http://www.tramontana.co.hu/wix/lesson4.php and I am able to create a
> package which upgrades an existing installation with a minor upgrade.
> I install version 1.0.0 successfully.
> I then apply the upgrade via the command msiexec SampleUpgrade.msi -i
> REINSTALL=ALL REINSTALLMODE=vomus.  This is successful.
> However when I test the behaviour for when I reapply the upgrade I do
> not get the error message from the check on the whether it has
> previously been applied.  Instead the usual "Resuming the Foobar 1.0.1
> Setup Wizard" dialogs.  I would have thought that a combination of the
> relevant <UpgradeVersion>, <CustomAction> and <Custom> tags would result
> in an error.  Am I missing something subtle (or not so subtle) here?
> 
> Many thanks for any assistance!
> 
> Details follow:
> 
> I am using WiX v3.0.3704.0 and I have migrated the download files from
> v2 to v3 using wixcop, inserted my own guids and then modified the
> components to avoid the ICE errors regarding advertised shortcuts.
> 
> Version 1.0.0 of SampleUpgrade.wxs
> <?xml version="1.0" encoding="utf-8"?>
> <Wix xmlns="http://schemas.microsoft.com/wix/2006/wi";>
>   <Product Name="Foobar 1.0" Version="1.0.0" Manufacturer="Acme Ltd."
>            Id="{4C7E5CEC-492F-480d-80C4-ACD24B9B1D14}"
> UpgradeCode="{048F6EB0-9D0F-41f1-B98E-A813413CE61E}"
>            Language="1033" Codepage="1252">
> 
>     <Package Keywords="Installer" Description="Acme's Foobar 1.0
> Installer"
>              Comments="Foobar is a registered trademark of Acme Ltd."
> Manufacturer="Acme Ltd."
>              InstallerVersion="100" Languages="1033" Compressed="yes"
> SummaryCodepage="1252" />
> 
>     <Upgrade Id="{048F6EB0-9D0F-41f1-B98E-A813413CE61E}">
>       <UpgradeVersion OnlyDetect="yes" Property="NEWERFOUND"
> Minimum="1.0.0" IncludeMinimum="no" />
>     </Upgrade>
> 
>     <Media Id="1" Cabinet="Sample.cab" EmbedCab="yes" DiskPrompt="CD-ROM
> #1" />
>     <Property Id="DiskPrompt" Value="Acme's Foobar 1.0 Installation [1]"
> />
> 
>     <CustomAction Id="NoDowngrade" Error="A later version of
> [ProductName] is already installed." />
> 
>     <Directory Id="TARGETDIR" Name="SourceDir">
>       <Directory Id="ProgramFilesFolder" Name="PFiles">
>         <Directory Id="Acme" Name="Acme">
>           <Directory Id="INSTALLDIR" Name="Foobar 1.0" />
>         </Directory>
>       </Directory>
>       <Directory Id="ProgramMenuFolder" Name="PMenu">
>         <Directory Id="FoobarProgramsFolder" Name="Foobar 1.0" />
>       </Directory>
>       <Directory Id="DesktopFolder" Name="Desktop" />
>     </Directory>
> 
>     <DirectoryRef Id="INSTALLDIR">
> 
>       <Component Id="MainExecutable"
> Guid="{2BFB1CB4-30E2-4d82-948B-1F4699EDD633}">
>         <File Id="FoobarExe" Name="FoobarAppl10.exe" DiskId="1"
> Source="FoobarAppl10.exe" Vital="yes" />
>       </Component>
> 
>       <Component Id="HelperLibrary"
> Guid="{D49BE06F-419C-4d5e-9103-8CCA5EF33049}">
>         <File Id="HelperDll" Name="Helper.dll" DiskId="1"
> Source="Helper.dll" Vital="yes" />
>       </Component>
> 
>       <Component Id="Manual"
> Guid="{12086F0E-F12F-4267-A2DC-646D5138969A}">
>         <File Id="Manual" Name="Manual.pdf" DiskId="1"
> Source="Manual.pdf" />
>       </Component>
> 
>     </DirectoryRef>
> 
>     <DirectoryRef Id="FoobarProgramsFolder">
> 
>       <Component Id="FoobarShortcut"
> Guid="{9A400549-295C-46d5-BD89-44380E2A6E8C}">
>         <RegistryValue Root="HKCU" Key="Software\Acme\Foobar 1.0"
> Name="FoobarShortcutInstalled" Type="integer" Value="1" />
>         <Shortcut Id="FoobarStartMenu" Directory="FoobarProgramsFolder"
> Name="Foobar 1.0" Target="[INSTALLDIR]\FoobarAppl10.exe"
>                   Icon="Foobar10.exe" IconIndex="0" />
>         <Shortcut Id="FoobarDesktop" Directory="DesktopFolder"
> Name="Foobar 1.0" Target="[INSTALLDIR]\FoobarAppl10.exe"
>                   Icon="Foobar10.exe" IconIndex="0" />
>         <RemoveFolder Id="FoobarShortcut" On="uninstall" />
>       </Component>
> 
>       <Component Id="ManualShortcut"
> Guid="{0D70F635-9A0C-4e8e-925B-CCD1BDA0260A}">
>         <RegistryValue Root="HKCU" Key="Software\Acme\Foobar 1.0"
> Name="ManualShortcutInstalled" Type="integer" Value="1" />
>         <Shortcut Id="ManualStartMenu" Directory="FoobarProgramsFolder"
> Name="Instruction Manual" Target="[INSTALLDIR]\Manual.pdf" />
>         <RemoveFolder Id="ManualShortcut" On="uninstall" />
>       </Component>
> 
>     </DirectoryRef>
> 
>     <Feature Id="Complete" Title="Foobar 1.0" Description="The complete
> package." TypicalDefault="install" Display="expand" Level="1"
>              ConfigurableDirectory="INSTALLDIR">
>       <Feature Id="MainProgram" Title="Program" Description="The main
> executable." TypicalDefault="install" Level="1">
>         <ComponentRef Id="MainExecutable" />
>         <ComponentRef Id="HelperLibrary" />
>         <ComponentRef Id="FoobarShortcut" />
>       </Feature>
>       <Feature Id="Documentation" Title="Documentation"
> Description="RTFM!" Level="1">
>         <ComponentRef Id="Manual" />
>         <ComponentRef Id="ManualShortcut" />
>       </Feature>
>     </Feature>
> 
>     <UIRef Id="WixUI_Mondo" />
>     <UIRef Id="WixUI_ErrorProgressText" />
> 
>     <InstallExecuteSequence>
>       <Custom Action="NoDowngrade"
> After="FindRelatedProducts">NEWERFOUND</Custom>
>       <RemoveExistingProducts After="InstallFinalize" />
>     </InstallExecuteSequence>
> 
>     <Icon Id="Foobar10.exe" SourceFile="FoobarAppl10.exe" />
>   </Product>
> </Wix>
> 
> Version 1.0.1 of SampleUpgrade.wxs
> <?xml version="1.0" encoding="utf-8"?>
> <Wix xmlns="http://schemas.microsoft.com/wix/2006/wi";>
>   <Product Name="Foobar 1.0.1" Version="1.0.1" Manufacturer="Acme Ltd."
>            Id="{4C7E5CEC-492F-480d-80C4-ACD24B9B1D14}"
> UpgradeCode="{048F6EB0-9D0F-41f1-B98E-A813413CE61E}"
>            Language="1033" Codepage="1252">
> 
>     <Package Keywords="Installer" Description="Acme's Foobar 1.0.1
> Updater"
>              Comments="Foobar is a registered trademark of Acme Ltd."
> Manufacturer="Acme Ltd."
>              InstallerVersion="100" Languages="1033" Compressed="yes"
> SummaryCodepage="1252" />
> 
>     <Upgrade Id="{048F6EB0-9D0F-41f1-B98E-A813413CE61E}">
>       <UpgradeVersion OnlyDetect="yes" Property="PATCHFOUND"
> Minimum="1.0.1" IncludeMinimum="yes" Maximum="1.0.1"
> IncludeMaximum="yes" />
>       <UpgradeVersion OnlyDetect="yes" Property="NEWERFOUND"
> Minimum="1.0.1" IncludeMinimum="no" />
>     </Upgrade>
> 
>     <Media Id="1" Cabinet="Sample.cab" EmbedCab="yes" DiskPrompt="CD-ROM
> #1" />
>     <Property Id="DiskPrompt" Value="Acme's Foobar 1.0 Installation [1]"
> />
> 
>     <CustomAction Id="AlreadyUpdated" Error="[ProductName] is already
> installed." />
>     <CustomAction Id="NoDowngrade" Error="A later version of
> [ProductName] is already installed." />
> 
>     <Directory Id="TARGETDIR" Name="SourceDir">
>       <Directory Id="ProgramFilesFolder" Name="PFiles">
>         <Directory Id="Acme" Name="Acme">
>           <Directory Id="INSTALLDIR" Name="Foobar 1.0" />
>         </Directory>
>       </Directory>
>       <Directory Id="ProgramMenuFolder" Name="PMenu">
>         <Directory Id="FoobarProgramsFolder" Name="Foobar 1.0" />
>       </Directory>
>       <Directory Id="DesktopFolder" Name="Desktop" />
>     </Directory>
> 
>     <DirectoryRef Id="INSTALLDIR">
> 
>       <Component Id="MainExecutable"
> Guid="{2BFB1CB4-30E2-4d82-948B-1F4699EDD633}">
>         <File Id="FoobarExe" Name="FoobarAppl10.exe" DiskId="1"
> Source="FoobarAppl10.exe" Vital="yes" />
>       </Component>
> 
>       <Component Id="HelperLibrary"
> Guid="{D49BE06F-419C-4d5e-9103-8CCA5EF33049}">
>         <File Id="HelperDll" Name="Helper.dll" DiskId="1"
> Source="Helper.dll" Vital="yes" />
>       </Component>
> 
>       <Component Id="Manual"
> Guid="{12086F0E-F12F-4267-A2DC-646D5138969A}">
>         <File Id="Manual" Name="Manual.pdf" DiskId="1"
> Source="Manual.pdf" />
>       </Component>
> 
>     </DirectoryRef>
> 
>     <DirectoryRef Id="FoobarProgramsFolder">
> 
>       <Component Id="FoobarShortcut"
> Guid="{9A400549-295C-46d5-BD89-44380E2A6E8C}">
>         <RegistryValue Root="HKCU" Key="Software\Acme\Foobar 1.0"
> Name="FoobarShortcutInstalled" Type="integer" Value="1" />
>         <Shortcut Id="FoobarStartMenu" Directory="FoobarProgramsFolder"
> Name="Foobar 1.0" Target="[INSTALLDIR]\FoobarAppl10.exe"
>                   Icon="Foobar10.exe" IconIndex="0" />
>         <Shortcut Id="FoobarDesktop" Directory="DesktopFolder"
> Name="Foobar 1.0" Target="[INSTALLDIR]\FoobarAppl10.exe"
>                   Icon="Foobar10.exe" IconIndex="0" />
>         <RemoveFolder Id="FoobarShortcut" On="uninstall" />
>       </Component>
> 
>       <Component Id="ManualShortcut"
> Guid="{0D70F635-9A0C-4e8e-925B-CCD1BDA0260A}">
>         <RegistryValue Root="HKCU" Key="Software\Acme\Foobar 1.0"
> Name="ManualShortcutInstalled" Type="integer" Value="1" />
>         <Shortcut Id="ManualStartMenu" Directory="FoobarProgramsFolder"
> Name="Instruction Manual" Target="[INSTALLDIR]\Manual.pdf" />
>         <RemoveFolder Id="ManualShortcut" On="uninstall" />
>       </Component>
> 
>     </DirectoryRef>
> 
>     <Feature Id="Complete" Title="Foobar 1.0" Description="The complete
> package." TypicalDefault="install" Display="expand" Level="1"
>              ConfigurableDirectory="INSTALLDIR">
>       <Feature Id="MainProgram" Title="Program" Description="The main
> executable." TypicalDefault="install" Level="1">
>         <ComponentRef Id="MainExecutable" />
>         <ComponentRef Id="HelperLibrary" />
>         <ComponentRef Id="FoobarShortcut" />
>       </Feature>
>       <Feature Id="Documentation" Title="Documentation"
> Description="RTFM!" Level="1">
>         <ComponentRef Id="Manual" />
>         <ComponentRef Id="ManualShortcut" />
>       </Feature>
>     </Feature>
> 
>     <UIRef Id="WixUI_Mondo" />
>     <UIRef Id="WixUI_ErrorProgressText" />
> 
>     <InstallExecuteSequence>
>       <Custom Action="AlreadyUpdated"
> After="FindRelatedProducts">PATCHFOUND</Custom>
>       <Custom Action="NoDowngrade"
> After="FindRelatedProducts">NEWERFOUND</Custom>
>       <RemoveExistingProducts After="InstallFinalize" />
>     </InstallExecuteSequence>
> 
>     <Icon Id="Foobar10.exe" SourceFile="FoobarAppl10.exe" />
>   </Product>
> </Wix>
> 
> 
> This email and any files transmitted with it are confidential, and may be 
> subject to legal privilege, and are intended solely for the use of the 
> individual or entity to whom they are addressed. 
> If you have received this email in error or think you may have done so, you 
> may not peruse, use, disseminate, distribute or copy this message. Please 
> notify the sender immediately and delete the original e-mail from your system.
> 
> -------------------------------------------------------------------------
> This SF.net email is sponsored by: Microsoft
> Defy all challenges. Microsoft(R) Visual Studio 2008.
> http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/


-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
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