Custom Action: How to Ignore return codes? - Advanced Installer Community
gmeisel
Posts: 7
Joined: Tue Oct 31, 2017 2:32 pm

Custom Action: How to Ignore return codes?

I am using a custom action to automatically launch a third party installation executable and have no control of any of the codes that may be returned from it. How can I get the updater to not show the ambiguous error page reporting that some files didn't install correctly. This seems to happen even if the user completely finishes the installation of the third party program. How can I get it to not show this error page? The installation of this custom feature is optional, and users can cancel it without harm to our main program. It is confusing and worrying our customers
Dan
Posts: 4530
Joined: Wed Apr 24, 2013 3:51 pm

Re: Custom Action: How to Ignore return codes?

Hello and welcome to Advanced Installer forums,

Indeed, any code besides zero that a executable custom action returns is interpreted as an error by Windows Installer.

A possible fix for this would be to ignore the return code of the executable file. For this, you can go in the Custom Actions view and disable the "Fail installation if custom action returns an error" option from the custom action properties.

If this does not solve the issue, can you please send us the .AIP (project),a screnshoot of the error and verbose log of the installation to support at advancedinstaller dot com so we can investigate them?

Best regards,
Dan
Dan Ghiorghita - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
gmeisel
Posts: 7
Joined: Tue Oct 31, 2017 2:32 pm

Re: Custom Action: How to Ignore return codes?

Dan,

Thank you for your reply, but I have already researched those pages and the one thing that is never made clear, is how exactly do you add the ignore return code flag into AI interface? I already tried inserting both the the constant "msidbCustomActionTypeContinue" or its decimal "64", into AI's Execution Condition with no luck.

Can you please outline just how you are supposed to implement it?

Thanks
gmeisel
Posts: 7
Joined: Tue Oct 31, 2017 2:32 pm

Re: Custom Action: How to Ignore return codes?

Dan,

Attached are the files you requested. I did review the log and see that yes the third party installer is apparently returning a "1". I just need to how to get AI to ignore it.

Thanks,
Attachments
UpdateErrorWindow.PNG
UpdateErrorWindow.PNG (11.27 KiB) Viewed 10820 times
AV-Playback Lite.aip
(87.1 KiB) Downloaded 784 times
gmeisel
Posts: 7
Joined: Tue Oct 31, 2017 2:32 pm

Re: Custom Action: How to Ignore return codes?

Dan,

If I try to attach the log file I get "Sorry, the board attachment quota has been reached." error

Sorry
gmeisel
Posts: 7
Joined: Tue Oct 31, 2017 2:32 pm

Re: Custom Action: How to Ignore return codes?

Dan,

I am re-thinking my position on this issue... It appears that perhaps the error prompt isn't from the custom actions at all, instead it is something else. I have created a separate update version of our installer. It does not contain any custom actions, but yet when it is executed inside the Updater, the updater is the one that is reporting the error. Just so you know, when either the full or update version is started directly from windows explorer, installation goes fine and no errors appear. It is only when it is executed via you updater utility.

Any thoughts?
Dan
Posts: 4530
Joined: Wed Apr 24, 2013 3:51 pm

Re: Custom Action: How to Ignore return codes?

Hello Gmeisel

After some investigation of your project it seems that your update install detection may not be set up correctly.
Could you set up your Updates Configuration project --> Update Install Detection --> Registry Value to the following value:

Code: Select all

HKLM\SOFTWARE\AV-Playback\Version
UpdateInstalledDetection.png
UpdateInstalledDetection.png (22.92 KiB) Viewed 10805 times
Any update defined in the Updates Configuration file uses a detection criteria. This criteria is usually a file or a registry entry which contains the package version. If it's not met after the update is installed, the Updater will show this message. Therefore,you need to make sure that you specified a correct file or registry entry in the Installed Detection tab of the Update Properties page.

Please let us know if this has solved the issue.

Best regards,
Dan
Dan Ghiorghita - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
gmeisel
Posts: 7
Joined: Tue Oct 31, 2017 2:32 pm

Re: Custom Action: How to Ignore return codes?

Dan,

You suggestion also tips on another issue I see... It appears that the installer is not actually writing to the Registry? I have experimented with a number of different combinations but each time it never creates the new reg keys, (if none exist.)

Thoughts?
Dan
Posts: 4530
Joined: Wed Apr 24, 2013 3:51 pm

Re: Custom Action: How to Ignore return codes?

Hello Gmeisel,

If you are running a 32-bit installation on a 64-bit OS, your registry entries are automatically redirected to WOW6432Node. This is standard Windows Installer behaviour.

Please refer to the following article for more information Wow6432Node Registry Key.

We have tested your installation on a clean machine with 64-bit OS and it created the following entries:

Code: Select all

HKLM\Software\Wow6432Node\AV-Playback
Could you please check if this is the case?

Best regards,
Dan
Dan Ghiorghita - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
gmeisel
Posts: 7
Joined: Tue Oct 31, 2017 2:32 pm

Re: Custom Action: How to Ignore return codes?

Yes, I just figured that out, and yes I now have it including Wow6432Node in the path. Now at least the updater detects that the current version exists and doesn't allow the download. Still a bit inconclusive to whether or not it will stop the error prompt. Every time I test against and earlier version I still get the error.
Dan
Posts: 4530
Joined: Wed Apr 24, 2013 3:51 pm

Re: Custom Action: How to Ignore return codes?

Hello Gmeisel,
Yes, I just figured that out, and yes I now have it including Wow6432Node in the path.
Please note that you do not have to include "Wow6432Node" in your path as it is automatically redirected there by Windows Installer.Keep in mind that this happens when you are running a 32-bit application on a 64-bit OS.
Still a bit inconclusive to whether or not it will stop the error prompt. Every time I test against and earlier version I still get the error.
If you are receving the error promt, but your update is downloaded and installed, it means is that your "Update Installed Detection" is not set up correctly.
Also, please take a look at the "Do not try to detect if the update was installed" option from Update Install Detection tab.This option disables detecting the update installation after the update was installed and you won't be notified if your update installed succesfully either.

Best regards,
Dan
Dan Ghiorghita - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”