[wix-users] Detect Custom Action Execute Mode

Rob Mensching rob at firegiant.com
Mon Apr 9 10:07:00 PDT 2018


::MsiGetMode() - https://msdn.microsoft.com/en-us/library/windows/desktop/aa370125(v=vs.85).aspx

_____________________________________________________________
 Short replies here. Complete answers over there: http://www.firegiant.com/

-----Original Message-----
From: wix-users <wix-users-bounces at lists.wixtoolset.org> On Behalf Of Edwin Castro via wix-users
Sent: Monday, April 9, 2018 9:33 AM
To: WiX Toolset Users Mailing List <wix-users at lists.wixtoolset.org>
Cc: Edwin Castro <egcastr at gmail.com>
Subject: [wix-users] Detect Custom Action Execute Mode

Is it possible to detect if a custom action is running immediate, deferred, or rollback? I'm wondering if it makes sense to have a single entry point instead of three...

I suppose checking for custom action data could help me here since the absence of custom action data indirectly indicates immediate mode while the existence of custom action data indicates deferred or rollback mode. I suppose the custom action data itself could tell me if I'm running rollback or not...

Those thoughts feel hackish... Is there an idiomatic way to do this?
Presumably, the Windows Installer engine implements standard actions similarly to how custom actions are implemented and they don't seem to have separate immediate, deferred, rollback, and commit standard actions... but perhaps they do and we just can't see them.

--
Edwin G. Castro

____________________________________________________________________
WiX Toolset Users Mailing List provided by FireGiant http://www.firegiant.com/


More information about the wix-users mailing list