I'm trying to launch the software I'm installing with some parameter after the install to perform an initialization task. I want to launch the custom action only after the first install and not after an upgrade.
The following code launches the custum action after both the first install and an upgrade.
<CustomAction Id="MyAction"
Directory="TARGETDIR"
ExeCommand="[INSTALL_ROOT]MySoft.exe myarg"
Execute="immediate"
Return="ignore"
Impersonate="yes" />
<InstallExecuteSequence>
<Custom Action="MyAction" After='InstallFinalize'>(NOT Installed) AND (NOT UPGRADINGPRODUCTCODE) </Custom>
</InstallExecuteSequence>
What is the issue?