Uninstallation condition for WIX

2019-09-09 16:47发布

For installation, we have a property "Install" which we can use in conditions to execute if its undergoing installation. Do we have a similar property for Uninstallation?

1条回答
迷人小祖宗
2楼-- · 2019-09-09 17:13

You can use REMOVE~="ALL" to detect a full uninstallation.


An uninstall performed as part of a major upgrade can be detected via the UPGRADINGPRODUCTCODE property.


Here is some further advice and some help resources: here is a "MSI Conditions Cheat Sheet" to help you get the complicated MSI conditions for custom actions right. The sheet looks fine to me, but I have not tested it in detail - just sharing the link with your own testing as the only guarantee.

Also, you can check out Stefan Kruger's msifaq.com for a list of common MSI questions as well as his main installsite.org site for general deployment information.

With regards to Wix check out this well known wix tutorial. I'll throw in a link to the Windows Installer Best Practices list as well.

How to add a WiX custom action that happens only on uninstall (via MSI)?

查看更多
登录 后发表回答