Jump to content


This is a ready-only archive of the InstallSite Forum. You cannot post any new content here. / Dies ist ein Archiv des InstallSite Forums. Hier können keine neuen Beiträge veröffentlicht werden.
Photo

Exclusive Features


1 reply to this topic

Pizzero

Pizzero
  • Full Members
  • 22 posts

Posted 05 November 2007 - 12:12

My problem is in principle very simple, however I have some difficulties, as I'm new to msi installer:

In my installation I have a set of features that must be installed mutually exclusive on the target system.

Being a good practice (and after an inquiry perhaps being one of the few reasonable alternatives) in this case I have authored a new dialog which uses RadioButtons to ensure exclusiveness at the UI level. Then the features can be mutually selected with AddLocal and Remove ControlEvents of a PushButton.

But how can mutual exclusiveness be guaranteed if the Installer does not run at full UI level and the dialog will not be shown?
How do I ensure an initial selection of certain features based on a property? (as I have understood standard/custom actions to do this are not available and that e.g. MsiUseFeature functions are not allowed...)

To complicate matters further, the underlying components use identical file names (that's also a reason why they must be mutual exclusive) and I don't know how this does interfere with windows installer. I want that maintainance and repair installations work properly...

(If the feature selection state is based on a local property, would I have to save the property then? (so that repair and maintainance installations will work properly either in full UI mode or not?))

[huh.gif Before using features in my BASIC-MSI-project, I have had only components that had to be installed mutually exclusive. To accomplish this I used mutually exclusive conditions, which was a very robust and secure installation, as never two components could get installed. I easily initialized the component-conditions by initializing a property with a custom action. However the drawbacks - which also seem to be well known with msi projects - were that these component-conditions were evaluated once at "CostFinalize" and then gave static results, e.g. in an SelectionTree (Installshield: in CustomSetup dialog) and wishing to modify the installation in a maintainance installation, one had to mark the components as transitive.
Another very nice thing was that with this approach I could use two orthogonal parameters, i.e. I could use feature-states and then the component-conditions to select of the remaining features/components, which I think (?) is not possible when only using features and subfeatures. e.g. for a language selection task for 2 features A and B one would have to include the subfeatures A_english and B_english, compared to the 2 independent selections feature A and condition "english"...]


Thank you very much in advance!

Stefan Krueger

Stefan Krueger

    InstallSite.org

  • Administrators
  • 13,269 posts

Posted 06 November 2007 - 13:02

You can set ADDLOCAL and REMOVE properties with a list of features on the command line.
You can use feature levels and feature conditions based on properties that are set on the command line.
You can use type 19 ("display error message and abort") custom actions to enforce mutually exclusive features, using a condition based on feature selection state.