K7LER
Posts: 21
Joined: Wed Jan 12, 2022 7:33 pm

CA being called during upgrade when it shouldn't

Fri Jan 21, 2022 2:56 am

I have a custom action C# dll that brings up a form asking for items that will need to be deleted when uninstalling.

I ONLY want it to be called when the user chooses to uninstall the program. I don't want it to be called when the users runs an update.

I have the Execution Stage Condition on the CA checked as Uninstall and the condition REMOVE = "ALL".

What am I missing as it still gets called.

Liviu
Posts: 1035
Joined: Tue Jul 13, 2021 11:29 am
Contact:  Website

Re: CA being called during upgrade when it shouldn't

Fri Jan 21, 2022 3:20 pm

Hi,

This is quite strange.

I've tested this but I cannot reproduce the issue.

Can you please try the "Regular uninstall" option and let me know if it works for you?
regular uninstall.png
regular uninstall.png (9.44KiB)Viewed 2955 times

You can also add in the "Condition" field the NOT UPGRADINGPRODUCTCODE condition. Also, as another solution, you can directly set the "Condition" field like this:

Code: Select all

( Installed AND ( REMOVE = "ALL" OR AI_INSTALL_MODE = "Remove" ) AND NOT UPGRADINGPRODUCTCODE )

Let us know if this helped, otherwise can you please send us the .AIPs (project file) for both versions (v1 and v2) and an installation log by email to support at advancedinstaller dot com so we can further test and investigate this?

Best regards,
Liviu
________________________________________
Liviu Sandu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

K7LER
Posts: 21
Joined: Wed Jan 12, 2022 7:33 pm

Re: CA being called during upgrade when it shouldn't

Fri Jan 21, 2022 6:43 pm

I'll try this.

If using the control condition, should the checkbox options be unselected? Do they need to be set alongside the control condition?

K7LER
Posts: 21
Joined: Wed Jan 12, 2022 7:33 pm

Re: CA being called during upgrade when it shouldn't

Fri Jan 21, 2022 8:41 pm

Confirming that checking Regular Uninstall without a condition properly did not bring up the custom action when installing an update. And confirmed that it did when selecting to uninstall the application.

Liviu
Posts: 1035
Joined: Tue Jul 13, 2021 11:29 am
Contact:  Website

Re: CA being called during upgrade when it shouldn't

Tue Jan 25, 2022 9:11 am

Hi,

I'm glad it works as expected now.

Please let us know if you have any other questions.

Best regards,
Liviu
________________________________________
Liviu Sandu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Building Installers”