Custom action condition: Feature install or upgrade - Advanced Installer Community

We’re moving our forums to a new platform.

You can still browse and search existing topics, but you can no longer create new topics or post replies.

For questions, technical issues, or feature requests, please don’t hesitate to contact our support team at support@advancedinstaller.com.

Thank you for your understanding!

PeterM
Posts: 19
Joined: Fri Mar 29, 2013 9:28 pm

Custom action condition: Feature install or upgrade

To give a scenario:
- I have version 1.0 of my application, product code: {176AAAAA-F702-4C27-AF93-5B6BDDDDC34A}
- It has a feature called Web
- Customer installs 1.0, selects Web feature
- I release version 1.1. of my application
- Customer installs 1.1 as upgrade to existing 1.0 install

In the new version 1.1, I have a custom action that I only want run the first time a feature is ever installed OR if the feature is already installed and the customer is upgrading from 1.0

My condition:
((&Web = 3) AND NOT (!Web = 3)) OR (&Web = 5 AND OLDPRODUCTS = "{176AAAAA-F702-4C27-AF93-5B6BDDDDC34A}")

This works for me based on some simple test projects, but is this the preferred/recommended way to structure this condition?
Daniel
Posts: 8283
Joined: Mon Apr 02, 2012 1:11 pm
Contact: Website

Re: Custom action condition: Feature install or upgrade

Hello,

Yes, you can use the above condition for your scenario.

If you have any questions let us know.

All the best,
Daniel
Daniel Radu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”