我有两个 Wix 项目 - 一个创建 MSI,另一个将其引导到 exe 中。
使用 exe,我可以毫无问题地安装应用程序,但是当我尝试卸载应用程序时,我会再次获得安装程序的设置菜单并尝试再次自行安装。
如果我取消重新安装并尝试再次卸载,它会按预期工作。
如果我使用 msi 执行相同的工作流程,它会按预期工作。
这是我的引导程序的样子:
<Bundle Name="name" Version="2.0.0.0" Manufacturer="company" UpgradeCode="guid" IconSourceFile="icon.ico" DisableModify="yes">
<BootstrapperApplicationRef Id="WixStandardBootstrapperApplication.RtfLicense">
<bal:WixStandardBootstrapperApplication LicenseFile="license.rtf" SuppressOptionsUI="yes" SuppressRepair="yes" />
</BootstrapperApplicationRef>
<Chain>
<MsiPackage SourceFile="application.msi" DisplayInternalUI="yes" EnableFeatureSelection="yes"/>
</Chain>
</Bundle>
有任何想法吗?
更新
根据建议,我已将捆绑包修改为以下内容(将 EnableFeatureSelection 设置为 no),但它仍然显示相同的行为。
<Bundle Name="name" Version="2.0.0.0" Manufacturer="company" UpgradeCode="guid" IconSourceFile="icon.ico" DisableModify="yes">
<BootstrapperApplicationRef Id="WixStandardBootstrapperApplication.RtfLicense">
<bal:WixStandardBootstrapperApplication LicenseFile="license.rtf" SuppressOptionsUI="yes" SuppressRepair="yes" />
</BootstrapperApplicationRef>
<Chain>
<MsiPackage SourceFile="application.msi" DisplayInternalUI="yes" EnableFeatureSelection="no"/>
</Chain>
</Bundle>
更新#2
我注意到,当我第一次卸载并启动安装设置时,如果我取消设置,它会失败,但它已经删除了所有文件和注册表项。第二次运行卸载从添加/删除程序中删除条目(成功)。
更新#3
这是 msi 的 UI 序列
<UI>
<DialogRef Id="WelcomeDlg"/>
<DialogRef Id="LicenseAgreementDlg"/>
<DialogRef Id="VerifyReadyDlg"/>
<DialogRef Id="ErrorDlg" />
<DialogRef Id="FatalError" />
<DialogRef Id="FilesInUse" />
<DialogRef Id="UserExit" />
<DialogRef Id="SelectDbDlg" />
<Publish Dialog="WelcomeDlg" Control="Next" Event="NewDialog" Value="LicenseAgreementDlg"></Publish>
<Publish Dialog="LicenseAgreementDlg" Control="Back" Event="NewDialog" Value="WelcomeDlg">NOT Installed</Publish>
<Publish Dialog="LicenseAgreementDlg" Control="Next" Event="NewDialog" Value="SelectDbDlg">NOT Installed</Publish>
<Publish Dialog="SelectDbDlg" Control="Back" Event="NewDialog" Value="LicenseAgreementDlg">NOT Installed</Publish>
<Publish Dialog="SelectDbDlg" Control="Next" Event="NewDialog" Value="DbCreateCredDlg">NOT Installed</Publish>
<Publish Dialog="DbCreateCredDlg" Control="Back" Event="NewDialog" Value="SelectDbDlg">NOT Installed</Publish>
<Publish Dialog="DbCreateCredDlg" Control="Next" Event="NewDialog" Value="SetupTypeDlg">NOT Installed</Publish>
<Publish Dialog="SetupTypeDlg" Control="Back" Event="NewDialog" Value="DbCreateCredDlg">NOT Installed</Publish>
<Publish Dialog="SetupTypeDlg" Control="Next" Event="NewDialog" Value="FeaturesDlg">NOT Installed</Publish>
<Publish Dialog="SetupTypeDlg" Control="CustomButton" Event="NewDialog" Value="FeaturesDlg">NOT Installed</Publish>
<Publish Dialog="SetupTypeDlg" Control="TypicalButton" Event="NewDialog" Value="VerifyReadyDlg">NOT Installed</Publish>
<Publish Dialog="SetupTypeDlg" Control="CompleteButton" Event="NewDialog" Value="VerifyReadyDlg">NOT Installed</Publish>
<Publish Dialog="FeaturesDlg" Control="Back" Event="NewDialog" Value="SetupTypeDlg">NOT Installed</Publish>
<Publish Dialog="VerifyReadyDlg" Control="Back" Event="NewDialog" Value="SetupTypeDlg">NOT Installed</Publish>
<Publish Dialog="ExitDialog" Control="Back" Event="EndDialog" Value="VerifyReadyDlg">1</Publish>
<Publish Dialog="ExitDialog" Control="Finish" Event="EndDialog" Value="Return" Order="999">1</Publish>
</UI>