nchounlapane
Posts: 28
Joined: Tue Mar 31, 2020 10:01 pm

Post-install prerequisites not installing on upgrade

Thu Jan 13, 2022 4:52 pm

Advanced Installer v16.7

I currently have a custom dialog that sets an install parameter (i.e FEATURE_INSTALL) to either True or False based on a checkbox value. This install parameter will be used for the installation behavior condition for a post-install feature. The installation behavior for the feature is set to 'Not installed', with 'Installed if' set to FEATURE_INSTALL = "True".

The feature installs as expected on first-time install of the application if condition is true, but on application upgrade (where the feature is initially not installed) does not install the prerequisite.

I'm aware of the built-in dialogs (PrerequisiteDlg and OptionalFeatsDlg) that would be able to handle my issue but I need to create a custom dialog. Attached is a sample project that has a similar setup to our main project.

Nick
Attachments
Feature install test.aip
(26.11KiB)Downloaded 132 times

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

Re: Post-install prerequisites not installing on upgrade

Fri Jan 14, 2022 10:58 am

Hi Nick,

This is happening due to the "MigrateFeatureState" action, whose purpose is to take the state of the features from the old package and transfer that to the new package.

In order to avoid this, please proceed as it follows:

  • In the newer version of your project:

    1. Go to the “Upgrades” page.

    2. Check the “Customize Advanced Installer upgrade rules” option from the “Application Versions” section.

    3. In the "Upgrades" table, double click on the upgrade code which has the property set to "OLDPRODUCTS".

    4. Select the “Upgrade Action” tab and uncheck the “Enable Migrate Features action” option.
    MigrateFeature.png
    MigrateFeature.png (47.29KiB)Viewed 2437 times

Hope this helps! If you have any other questions please don't hesitate to contact us.

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

nchounlapane
Posts: 28
Joined: Tue Mar 31, 2020 10:01 pm

Re: Post-install prerequisites not installing on upgrade

Fri Jan 14, 2022 7:04 pm

Thank you, Liviu. It is now working as expected!

Nick

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

Re: Post-install prerequisites not installing on upgrade

Mon Jan 17, 2022 7:50 am

You're welcome, Nick!

If you have any other questions, please don’t hesitate to contact us.

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

Return to “Common Problems”