Read installation path from registry - 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!

Pinky
Posts: 1
Joined: Tue Oct 12, 2010 1:49 pm

Read installation path from registry

The situation I'm trying is the following:
Some other installer may set a registry value with the installation path. If the registry key is present we should use that location, else we need the default [ProgramFilesDir][Manufacturer]\[ProductName] location.
I've tried creating a search containing the registry, but how do I set the conditional folder location? When I set the Application Folder to the search value, the application is able to retrieve the key correctly, but when the key is missing the location "c:\APPDIR" is selected instead of "C:\Program files\...". Is there anyway I can implement this feature?

Thanks in advance!
GabrielBarbu
Posts: 2146
Joined: Thu Jul 09, 2009 11:24 am
Contact: Website

Re: Read installation path from registry

Hello and welcome to Advanced Installer Forums,

Since you are new, I highly recommend you read our tutorials for a better understanding of how to use Advanced Installer to efficiently deploy your products.
This will also help you better understand support team's suggestions now and in the future. The simple and professional tutorials are especially important.

You will be interested in setting the APPDIR property after the AppSearch standard action using a Property set with Formatted custom action. Since you are using a path from the registry, you might also want to conditionally display the FolderDlg dialog depending on whether or not you have the registry value containing the path.

Best regards,
Gabriel
Gabriel Barbu
Advanced Installer Team
http://www.advancedinstaller.com/

Return to “Common Problems”