jbaynton
Posts: 15
Joined: Tue Jan 29, 2013 8:35 pm

Suppress error message when custom action returns failure

Hi,

I'm trying to accomplish the following:
1. Run an executable (at the end of the Wizard Dialogs Stage) that will check a bunch of prerequisites (that aren't checkable with built in functionality)
2. If the user selects to cancel the installation in the executable, cancel the installation as if they'd selected cancel at any point

I've tried the Launch File and Execute Inline Script Code custom actions with failure returning an assortment of values (-1,3, 1602) but every time I get the rather ugly message: "There is a problem with this Windows Installer package. A script required for this install could not be run. Contact your support personnel or package vendor."

While I understand that this is the appropriate message should an actual error occur, it's not procedurally correct in this scenario.

I've seen a bunch of questions similar to this in the forums (e.g. viewtopic.php?t=19183) but nothing's working. Am I stuck with this message?

Thanks,

Jeff
Eusebiu
Posts: 4931
Joined: Wed Nov 14, 2012 2:04 pm

Re: Suppress error message when custom action returns failure

Hi Jeff,

Indeed, the "Launch file" and "Execute inline script" custom actions display that error message in case an error return code is received. Can you try the "Launch attached file" or "Launch installed file" custom actions and see if they work.

You can see an example of this with a VBS custom action in the "how to Abort the Install on message box response" thread.

Best regards,
Eusebiu
Eusebiu Aria - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”