所以我有一个非常简单的刻录安装程序,主要是包括.net升级或偶尔包含我们的应用程序需要与之交谈的硬件驱动程序包。
MSI我们创建支持升级或降级。
<?xml version="1.0" encoding="UTF-8"?>
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi"
xmlns:bal="http://schemas.microsoft.com/wix/BalExtension">
<Bundle Name="My App Name" Manufacturer="Company Name" Version="!(bind.packageVersion.MyAPP_MSI)"
IconSourceFile="MyIcon.ico" DisableModify="yes" DisableRemove="yes"
UpgradeCode="{15E598EF-89CE-470B-8CEF-E32C8983DA33}" >
<BootstrapperApplicationRef Id="WixStandardBootstrapperApplication.RtfLicense" >
<bal:WixStandardBootstrapperApplication
LogoFile="$(var.CoreComponents.TargetDir)InstallerGraphics\Bootstrapper_Logo.png"
LicenseFile="$(var.CoreComponents.TargetDir)AppRoot\App License.rtf"
SuppressOptionsUI="yes" />
</BootstrapperApplicationRef>
<Chain>
<PackageGroupRef Id="NetFx451Web"/>
<MsiPackage DisplayName="My full Application Name" Id="MyAPP_MSI" SourceFile="$(var.Installer_MyAppMSI_TargetPath)"
DisplayInternalUI="yes" ForcePerMachine="yes" Visible="yes" />
<MsiPackage DisplayName="My Hardware Driver" Id="Installer_MSI_Driver" SourceFile="$(var.Installer_Driver.TargetPath)"
DisplayInternalUI="yes" ForcePerMachine="yes" Visible="yes" />
</Chain>
</Bundle>
</Wix>
我们通常会发布测试版,当用户想要从测试版降级到我们的稳定版时,他们只能执行旧的EXE安装程序。他们必须明确地从“添加/删除程序”中删除以前的程序包以安装较旧的Burn EXE。
这对基于MSI的安装来说不是问题。我们如何回到这个功能?
日志
[0CB8:067C][2014-06-23T11:10:04]i001: Burn v3.8.1128.0, Windows v6.1(Build 7601: Service Pack 1), path:\\iop-filesvr\IOP\Builds\Main\8.1.240\IO Practiceware Client Setup.exe, cmdline: '-burn.unelevated BurnPipe.{197B8193-6EFC-4ED0-AF90-DE7205F13E65} {CD23A8AB-520B-4F5D-BCB9-98998C5A1EC0} 2216'
[0CB8:067C][2014-06-23T11:10:04]i000: Setting string variable 'WixBundleLog' to value 'C:\Users\jeff\AppData\Local\Temp\IO_Practiceware_Client_8.1.240.0_20140623111004.log'
[0CB8:067C][2014-06-23T11:10:04]i000: Setting string variable'WixBundleOriginalSource' to value '\\iop-filesvr\IOP\Builds\Main\8.1.240\IO Practiceware ClientSetup.exe'
[0CB8:067C][2014-06-23T11:10:04]i000: Setting string variable 'WixBundleName' to value 'IO Practiceware Client 8.1.240.0'
[0CB8:067C][2014-06-23T11:10:05]i100: Detect begin, 2 packages
[0CB8:067C][2014-06-23T11:10:05]i000: Setting string variable 'PrerequisitesVersion' to value '1.0.0.0'
[0CB8:067C][2014-06-23T11:10:05]i102: Detected related bundle: {8d398d25-606f-419a-9b29-e3434aeb2485}, type: Upgrade, scope: PerUser, version: 8.1.241.0, operation: Downgrade
[0CB8:067C][2014-06-23T11:10:05]i103: Detected related package: {7EA877FF-CE7A-49CE-8F76-D5A11EA7DD7A}, scope: PerMachine, version: 1.0.0.0, language: 0 operation: MajorUpgrade
[0CB8:067C][2014-06-23T11:10:05]i103: Detected related package: {8E8A7689-FB1C-4FE5-AF7C-95D499A342DE}, scope: PerUser, version: 8.1.241.0, language: 0 operation: MajorUpgrade
[0CB8:067C][2014-06-23T11:10:05]i101: Detected package: PrerequisitesMsi, state: Absent, cached: None
[0CB8:067C][2014-06-23T11:10:05]i101: Detected package: ClientMsi, state: Absent, cached: None
[0CB8:067C][2014-06-23T11:10:05]i199:Detect complete, result: 0x0
[0CB8:076C][2014-06-23T11:10:16]i000: Setting numeric variable 'EulaAcceptCheckbox' to value 0
[0CB8:076C][2014-06-23T11:10:16]e000: Error 0x80070666: Cannot install a product when a newer version is installed.
答案 0 :(得分:2)
这对我有用:
<MajorUpgrade Schedule="afterInstallInitialize" AllowDowngrades="yes" />
答案 1 :(得分:1)
尝试在product.wxs文件中添加<Property Id="REINSTALLMODE" Value="amus" />
。 REINSTALLMODE属性是一组设置,用于定义具有不同/相同版本的新安装的行为。有关详细信息,请查看REINSTALLMODE property作为参考。
答案 2 :(得分:0)
将beta作为释放导致稳定(RC或市场)发布。文件/程序集版本总是向上移动,因此安装是升级。
采取这一系列的发布:
根据市场(稳定)版本或测试版来定义客户看到的版本。
查看&#39; AssemblyInformationalVersion&#39;。
[assembly: AssemblyVersion("1.0.0.1234")]
[assembly: AssemblyFileVersion("1.0.0.1234")]
[assembly: AssemblyInformationalVersion("1.0")]
始终升级。