rncox73
Posts: 18
Joined: Thu Jun 17, 2010 11:39 pm

Multiple Builds

I am doing two different builds in my project and I have an installed file that I want to make a shortcut to on the desktop. For branding purposes in one build it will be called one thing and in the second build it will be called something slightly different. I can't seem to figure how to do that. I've set the Feature drop down on the files and folders page but that doesn't help. I also want to run one SQL Script for one build and a slightly different SQL Script for the second build. How can I do that?

Thank you.
GabrielBarbu
Posts: 2146
Joined: Thu Jul 09, 2009 11:24 am
Contact: Website

Re: Multiple Builds

Hello,

You most likely created a "Shortcut to Installed File". These types of shortcuts can only reside within the same component as their target. Create a shortcut to External File instead, make sure you set its target correctly. These types of shortcuts can be moved from component to component and from feature to feature. I expect you won't encounter the same problem if you'll use this type of shortcut instead.
Also, SQL scripts have a condition field through which you can control whether a script executes or not.

Best regards,
Gabriel
Gabriel Barbu
Advanced Installer Team
http://www.advancedinstaller.com/
rncox73
Posts: 18
Joined: Thu Jun 17, 2010 11:39 pm

Re: Multiple Builds

Thank you. Also is it possible to set certain elements in an xml file depending on the feature/build being installed? I can't find how to do it in the help files.

I also want to be able to install a specific folder under the installation folder and install certain files there for one feature and a different set for a different feature. I can't seem to be able to create the directory a second time and add a different set of files for the different feature.
Bogdan
Posts: 2796
Joined: Tue Jul 07, 2009 7:34 am
Contact: Website

Re: Multiple Builds

Hi,
is it possible to set certain elements in an xml file depending on the feature/build being installed?
You can edit the content of the XML files at run-time using public properties. What you need to to is to change the content of the properties based on the selected features.
This can be done using our predefined custom action "Property Set with Formatted".

Also the custom action should be placed under the CostFinalize standard action from InstallExecuteSequence.
The condition of the custom action is set based on the feature's action.
I can't seem to be able to create the directory a second time and add a different set of files for the different feature.
You don't need to create the folder for each feature. All you have to do is to select the corespondent feature from the main toolbar for each file.

Regards,
Bogdan
Bogdan Mitrache - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
rncox73
Posts: 18
Joined: Thu Jun 17, 2010 11:39 pm

Re: Multiple Builds

Thank you. I've tried just that in regard to creating the folder and putting different files in the folder for each feature. However it doesn't work. If I select Feature 1 from the drop down and add the files and then select Feature 2 from the drop the files still show up there. If I then select the files from a different location it says they already exists and asks if I want to overwrite them. The point I did not make clear originally is that these are the same exact files but from a different source. It is a database file named exactly the same but the data is different for each feature.
Bogdan
Posts: 2796
Joined: Tue Jul 07, 2009 7:34 am
Contact: Website

Re: Multiple Builds

Hi,
If I select Feature 1 from the drop down and add the files and then select Feature 2 from the drop the files still show up there.
This is the normal behavior. Please note that the features combobox is there only to allow you to select the feature under which the files that you will add
will be placed. Its purpose is not to display in the view only the files from that feature.

In the files view all the files will be displayed, no matter what feature is selected.
The point I did not make clear originally is that these are the same exact files but from a different source. It is a database file named exactly the same but the data is different for each feature.
This is a completely different situation, I didn't realised from the previous post this is what you need. However, the solution is very simple, you can read it in the following article.

Please let us know if you have other questions.

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

Return to “Common Problems”