Search code examples
wixsequenceconditional-statementscustom-action

Wix - Run custom action when modifying existing install


I'm trying to run a custom action on first install and any subsequent modification(adding/removing features of the installed product).

Which condition should I check? I'm using the following but it doesn't work.

<InstallExecuteSequence>
  <Custom Action='SetParams' After='InstallFinalize'>NOT Installed OR WixUI_InstallMode = "Change"</Custom>
</InstallExecuteSequence>

Thanks


Solution

  • You can try this condition:

    REMOVE <> "ALL"
    

    It's true for a first time install and any maintenance operation except uninstall.