Search: Look for registry value in multiple locations - 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!

jwest
Posts: 56
Joined: Tue Dec 27, 2005 12:14 am

Search: Look for registry value in multiple locations

I have an AI installer that installs a PDF file to an existing installation of our software package.

This installer needs to determine where the PDF should go and so it uses an AI Search / Location / Registry to get the location from a registry value that our software package sets up when it is installed. This value contains the folder to which the program was installed. The AI project's Install Parameters / Installation Folders / Application Folder is set to [Name Of The Search] and it works well.

We recently released an update that changed the locations that we use to store this information so now I need to look at up to 3 different registry keys to determine the location. Only one of these keys will exist on the target machine.

How do I "OR" the search. I want to be able to set the AI project's Install Parameters / Installation Folders / Application Folder to

[Name Of The Search1] or [Name Of The Search2] or [Name Of The Search3]

Thanks
Bogdan
Posts: 2796
Joined: Tue Jul 07, 2009 7:34 am
Contact: Website

Re: Search: Look for registry value in multiple locations

Hi,

This can be done very easy. What you have to do is to use another property which will be set to
the result of the search that is resolved.

For this you will use three "Property set with formatted" custom actions, each one will set the new property to the value of the search of course if the search will be resolved (use it as a condition too). Please note that custom actions must be scheduled after the "AppSearch" standard action.

In the Install Parameters page you will have something like this:

Code: Select all

[NEW_PROP][ProductName]

Regards,
Bogdan
Bogdan Mitrache - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”