Testing if feature or component is installed locally on upgrade - Advanced Installer Community
MGS
Posts: 128
Joined: Tue Oct 04, 2022 9:52 am

Testing if feature or component is installed locally on upgrade

Hello,

I tried the following:
  1. Install the software
  2. Increase Version under Product Details View and generate a new Product Code
  3. Install Upgrade
And during the upgrade, I try to make use of a condition based on "Installed Feature X locally" and "Installed Component X locally".
So first I tried the following condition, which returned false: (!Service = 3)
Then I tried this condition, which also returned false: (?CompStorageService = 3)

Why is this the case? How can I find out if a feature/component is already installed while upgrading.

Best regards,
Johannes
Catalin
Posts: 7852
Joined: Wed Jun 13, 2018 7:49 am

Re: Testing if feature or component is installed locally on upgrade

Hello Johannes,

Both the conditions you are trying to use do indeed save the state of the feature/component (i.e. if it is installed, etc.), but on Maintenance mode.

If you want to condition an action based on the state of a component from the previous installation, you can use a search, i.e.:

- go to "Search" page

- craete a "New Extended Search" --> "Component is installed"
Screenshot_10.png
Screenshot_10.png (20.38 KiB) Viewed 7001 times

The property has the following values:

- 1 --> the search succeeds --> the component is installed

- empty --> the search fails --> the component is NOT installed

You can then use the property to condition what you need.

If you want to do the same for a feature, simply select a component from that feature that would always be installed.

Best regards,
Catalin
Catalin Gheorghe - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
MGS
Posts: 128
Joined: Tue Oct 04, 2022 9:52 am

Re: Testing if feature or component is installed locally on upgrade

Hello Catalin,

The description in the condition editor unintentionally led me to believe that I can use this condition to check if a function/component is installed. I could not find any indication that this only applies to maintenance mode.

Nevertheless, using the advanced search function worked fine, so thank you very much for the solution!

Best regards,
Johannes
Catalin
Posts: 7852
Joined: Wed Jun 13, 2018 7:49 am

Re: Testing if feature or component is installed locally on upgrade

You're always welcome, Johannes!

Best regards,
Catalin
Catalin Gheorghe - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”