如何使用WiX MBA卸载MSI,但不能卸载捆绑包本身?

编程入门 行业动态 更新时间:2024-10-25 12:23:52
本文介绍了如何使用WiX MBA卸载MSI,但不能卸载捆绑包本身?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我的要求:

我需要安装的MSI文件很少.用户可以选择他要安装/卸载的那个.为此,我使用了WiX引导程序,在其中使用WPF UI列出了所有MSI以及用于Intstall/Upgrade/Uninstall

I have few MSI files which need to be installed. User can select which one he wants to install/uninstall. For this purpose I have used WiX bootstrapper where I have used WPF UI to list down all the MSI and few buttons to Intstall/Upgrade/Uninstall

到目前为止,我可以使用InstallCondition安装选定的MSI,但无法管理卸载. 如果我卸载任何MSI,则捆绑软件也将被卸载.因此,它不会显示在添加/删除程序"中.

Till now I am able to install selected MSI using InstallCondition but could not manage the uninstall. If I uninstall any of the MSI, the Bundle is also getting uninstalled. Hence it is not showing in the Add/Remove Program.

所以我想知道是否有任何方法可以允许单个MSI的卸载,而不是捆绑软件本身的卸载?

So I would like to know if there is any way to allow uninstall of individual MSI but not the Bundle itself?

推荐答案

我猜因为您正在使用Engine.Plan(LaunchAction.Uninstall),因此您的捆绑软件已被卸载.如果您使用其他操作,例如Install或Modify,则不应将其删除.

I'm guessing your bundle is getting uninstalled because you are using Engine.Plan(LaunchAction.Uninstall). If you use a different action like Install or Modify, it shouldn't be removed.

要控制各个MSI软件包的安装状态,我认为您可以在PlanPackageBegin的回调中进行设置.

To control the install state of the individual MSI packages, I think you can set that in a callback to PlanPackageBegin.

更多推荐

如何使用WiX MBA卸载MSI,但不能卸载捆绑包本身?

本文发布于:2023-11-07 01:05:50,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1565133.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:如何使用   WiX   MSI   MBA

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!