有 3 个捆绑包,代码如下所示。1.0.0、1.0.0.1 和 2.0.0。
如果安装了 1.0.0、1.0.0.1 和 2.0.0,View Installed Updates 仍会将 1.0.0.1 列为已安装。它将保留在那里,直到卸载最后一个版本。
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
<Bundle Name="Burn Installer" Version="1.0.0" Manufacturer="LANSA" UpgradeCode="AAAAAAAA-AAAA-AAAA-AAAA-AAAAAAAAAAAA" Copyright="..." AboutUrl="...">
<BootstrapperApplicationRef Id="WixStandardBootstrapperApplication.RtfLicense" />
<Chain>
<MsiPackage Id="MainPackage" SourceFile="TESTLIST_v1.0.0_en-us.msi" Vital="yes" DisplayInternalUI="yes" />
</Chain>
</Bundle>
</Wix>
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
<Bundle Name="Patch 1.0.0.1" ParentName="Burn Installer" Version="1.0.0.1" Manufacturer="LANSA" UpgradeCode="AAAAAAAA-AAAA-AAAA-AAAA-AAAAAAAAAAAA" Copyright="..." AboutUrl="...">
<RelatedBundle Id="AAAAAAAA-AAAA-AAAA-AAAA-AAAAAAAAAAAA" Action="Patch"/>
<BootstrapperApplicationRef Id="WixStandardBootstrapperApplication.RtfLicense" />
<Chain>
<MspPackage Id="Patch" SourceFile="TESTLIST_v1.0.0.1_en-us.msp" Vital="yes" DisplayInternalUI="no" PerMachine="yes" Permanent="no"/>
</Chain>
</Bundle>
</Wix>
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
<Bundle Name="Burn Installer" Version="2.0.0" Manufacturer="LANSA" UpgradeCode="AAAAAAAA-AAAA-AAAA-AAAA-AAAAAAAAAAAA" Copyright="..." AboutUrl="...">
<BootstrapperApplicationRef Id="WixStandardBootstrapperApplication.RtfLicense" />
<Chain>
<MsiPackage Id="MainPackage" SourceFile="TESTLIST_v2.0.0_en-us.msi" Vital="yes" DisplayInternalUI="yes" />
</Chain>
</Bundle>
</Wix>
应用升级时,应从程序和功能和/或查看已安装的更新中删除所有以前的版本和补丁。与直接安装 MSI/MSP 而不是通过 Bundler 安装时发生的情况完全相同。