PDA

View Full Version : Setup Design



cnegrila
06-26-2006, 10:32 AM
This might be an easy one but I cannot seem to figure it out.

I have 3 features in the Setup Design and there is a file that I want to install if one or both of the first 2 features are selected by the user during install but not if just the 3rd is selected by itself (the file is needed only by the first two features).

I guess I could create a 4th dummy feature and group the 1st and 2nd features in it along with the common file, but this would make the user interface look odd - from the user's perspective this would seem artificial, wouldn't make much sense.

Is there another way to achieve this? Any hints would be greatly appreciated. :confused:

tw0001
06-26-2006, 10:51 AM
Best would be using script, using FeatureIsItemSelected and FeatureSelectItem.

i.e. if either of the two are selected (call FeatureIsItemSelected for both features), and if either return TRUE, then do a FeatureSelectItem on the third one you wish to install.

MichaelU
06-26-2006, 12:51 PM
If the project is MSI-based instead of pure InstallScript, you can set conditions on the component containing the auxiliary file that reference the installation states of the two features, or even just attach the component to both features.