Search code examples
wixcustom-actionfailed-installation

Wix: Which CustomAction is called just before showing the failure screen?


I have a requirement wherein I need to execute a custom action if the installer fails (either automatically or manually failed by returning ActionResult.Failure from another custom action). I tried <Custom Action="CallMe" After="InstallFinalize"></Custom> but the CA is not called. Any help is appreciated.

Edit: Found out from logs that it is "FatalError" custom action. But then doing this <Custom Action="CallMe" Before="FatalError"></Custom> throws Error 8 Unresolved reference to symbol 'WixAction:InstallExecuteSequence/FatalError' in section 'Product:*'


Solution

  • You can use

       <Custom Action="CallMeCancel" OnExit="cancel" /> 
       <Custom Action="CallMeError" OnExit="error" />
    

    The values for OnExit are success, cancel, error, suspend