删除“更改” MaintenaceTypeDialog 中的按钮
安装安装程序后,当用户再次单击安装程序以维护模式打开它时,我希望仅显示“修复”和“删除”选项,而不显示“更改”选项。
我可以使用 禁用“更改”按钮,但我想将其删除并且不想向用户显示它。
请建议这是否可行。
After installation of the setup, when the user again clicks on the setup to open it in the maintenance mode, I want that only the 'Repair' and 'Remove' options are shown and the 'Change' option is not shown.
I can disable the 'Change' button using but I want to remove it and don't want to display it to the user.
Please suggest if this is possible.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
您可以将 Wix 对话框集 (.wxs) 包含在您的安装程序项目中(它们可以从 git 下载)。编辑
MaintenanceTypeDlg.wxs
文件并删除修复按钮和标签。You can include the Wix dialog set (.wxs) in your installer project (they can be downloaded from git). Edit
MaintenanceTypeDlg.wxs
file and remove the repair button and label.查看以 ARPNO 前缀开头的 Windows Installer 属性:ARPNOMODIFY (这就是您所需要的),ARPNOREPAIR 和 ARPNOREMOVE。这些属性定义“添加/删除程序”控制台中选项的可用性。
希望这有帮助。
Take a look at the Windows Installer properties which start with ARPNO prefix: ARPNOMODIFY (this is what you need), ARPNOREPAIR and ARPNOREMOVE. These properties define the availability of option in Add/Remove Programs console.
Hope this helps.
如果您使用 WixUI_Mode 而不是使用自定义 MaintenanceTypeDlg.wxs,那么您应该定义
< /strong> 在 YOUR_MAIN_UI.wxs 文件中。If you are using WixUI_Mode and not using customized MaintenanceTypeDlg.wxs then you should define
<Property Id="ARPNOMODIFY" Value="1" />
in YOUR_MAIN_UI.wxs file.