Wix升级:预选功能
我们正在使用Wix创建安装程序。我们使用的是用户界面,用户可以在其中选择需要安装的功能。默认情况下,某些功能处于启用状态,而其他功能处于禁用状态 但是,当我们运行升级时,这些默认值将保留。我们希望安装程序记住安装了哪些功能,并在功能树中启用它们以进行升级。应禁用所有其他功能 我们有这样的代码,看起来很有效,但实际上,它没有:Wix升级:预选功能,wix,wix3,Wix,Wix3,我们正在使用Wix创建安装程序。我们使用的是用户界面,用户可以在其中选择需要安装的功能。默认情况下,某些功能处于启用状态,而其他功能处于禁用状态 但是,当我们运行升级时,这些默认值将保留。我们希望安装程序记住安装了哪些功能,并在功能树中启用它们以进行升级。应禁用所有其他功能 我们有这样的代码,看起来很有效,但实际上,它没有: <Feature Id="MainFeature" Level="1" ConfigurableDirectory="INSTALLDIR" Display="exp
<Feature Id="MainFeature" Level="1" ConfigurableDirectory="INSTALLDIR" Display="expand">
<Feature Id="Feature1" Level="1" InstallDefault="local" AllowAdvertise="no">
<ComponentGroupRef Id="Feature1ComponentGroup" />
<Condition Level="3">(PROJECTUPGRADE AND NOT !Feature1=2)</Condition>
</Feature>
<Feature Id="Feature2" Level="3" InstallDefault="local" AllowAdvertise="no">
<ComponentGroupRef Id="Feature2ComponentGroup" />
<Condition Level="1">(PROJECTUPGRADE AND !Feature2=2)</Condition>
</Feature>
</Feature>
(项目升级和否!功能1=2)
(项目升级和!功能2=2)
啊,看来我找错地方了。UpdgradeVersion标记上有一个名为“”的属性,用于指定以下内容:
<Upgrade Id="$(var.UpgradeCode)">
<UpgradeVersion Minimum="$(var.ProductVersion)" IncludeMinimum="yes" OnlyDetect="yes" Property="PROJECTDOWNGRADE" />
<UpgradeVersion Maximum="$(var.ProductVersion)" IncludeMaximum="no" Property="PROJECTUPGRADE" MigrateFeatures="yes" />
</Upgrade>