I have two custom actions, one of which I\'d like to execute when my product is installed and the other when it is uninstalled.
My custom action is currently called from
The variable “INSTALLED
” should be using is “Installed
”. Find more information regarding the Install and uninstall conditions in the Stack Overflow answer How to add a WiX custom action that happens only on uninstall (via MSI)?.
Try next
1.
Only for Installation:
<InstallExecuteSequence>
<Custom Action="SomeAction" After="InstallFinalize">NOT Installed AND NOT REMOVE</Custom>
</InstallExecuteSequence>
2.
For Uninstall try to use: Rob's answer
UPGRADINGPRODUCTCODE property is set only during RemoveExistingProducts
CA.