InstallShield 2014 » InstallScript Language Reference

Project: This information applies to the following project types:

InstallScript MSI

The SdFeatureMult function creates a dialog that displays the following:

A list of features and subfeatures that the end user can select for installation. The dialog has two feature lists. If the feature selected in the first list has subfeatures, the subfeatures are displayed in the second list.
The disk space required for the selected features and the space available in the destination location. A feature's size is displayed as 0 until it is selected. When the end user selects a feature, its actual size is displayed.
The description of a feature or subfeature. The end user can view the description by clicking on the feature or subfeature.


SdFeatureMult ( szTitle, szMsg, svDir, szFeatures );


SdFeatureMult Parameters




Specifies the title of the dialog. To display the default title (“Select Features”), pass a null string ("") in this parameter.


Specifies the message to display in the dialog. To display the default instructions for this dialog, pass a null string ("") in this parameter.


Specifies the name of the folder to be selected by default and returns the name of the folder selected by the end user. The destination folder specified by svDir is not assigned automatically to INSTALLDIR, TARGETDIR, or any other system variable. To apply the value of svDir to the setup, you must assign it to INSTALLDIR (in an InstallScript MSI installation), TARGETDIR (in an InstallScript installation), or to a script-defined variable, if one is in use.

If the default folder specified by svDir does not already exist on the end user's system, it is not created unless the end user clicks the Browse button and follows the steps to create it from the Choose Folder dialog. Therefore, whenever you specify a default folder, you must call ExistsDir when FeatureDialog returns in order to determine whether that folder exists. If it does not exist, call CreateDir to create it on the end user's system.


Specifies the name of the feature whose subfeatures are displayed. To display all top-level features, pass a null string ("") in this parameter. To learn how to refer to top-level features and subfeatures, see Specifying Features and Subfeatures in Function Calls.

SdFeatureMult searches for the requested features in the script-created feature set specified by the system variable MEDIA; see the Additional Information section.

Return Values

SdFeatureMult Return Values

Return Value


NEXT (1)

Indicates that the end user clicked the Next button.

BACK (12)

Indicates that the end user clicked the Back button.

Additional Information

To view an example of this or other dialogs for your installation, use the Dialog Sampler. In InstallShield, on the Tools menu, point to InstallScript, then click Standard Dialog Sampler or Skinned Dialog Sampler.
Default selection settings are cleared when the end user selects a feature or subfeature displayed in the dialog. If the end user clears a feature selection, all of its subfeatures are cleared. Conversely, if the end user clears all of a feature's subfeature selections, the feature's selection is cleared.

When a feature is not selected by default, its subfeatures are not selected by default. If all subfeatures of a feature are not selected by default, the parent feature should not be selected by default. See FeatureAddItem for information on default feature and subfeature selection settings.

A feature's size is displayed as 0 until it is selected. Once it has been selected, its actual size is displayed.
The required disk space displayed by the dialog includes the size of the files that must be installed to enable maintenance setups and uninstallation. Even if all application components are deselected, the size of these files is still displayed.
If your setup does not use a setup type dialog, you must call FeatureSetupTypeSet to specify a setup type that has been defined in the IDE's Setup Types view before calling SdFeatureMult.
SdFeatureMult operates on the current media, which is specified by the system variable MEDIA. During setup initialization, the installation assigns to MEDIA a media name that is associated with your file media library (

To display script-created features:

1. Save the current value of MEDIA in a string variable, for example, szSaveMEDIAValue.
2. Assign to MEDIA the name of the script-created component set.
3. Call SdFeatureMult to get end-user selections.
4. Assign to MEDIA the value that you saved in step 1. You must do this before calling FeatureTransferData.
If necessary, feature names are truncated to allow the display of the largest possible feature size. The space required to display the size depends on the maximum feature size (2 GB), the feature size options currently in use, and the font used to display feature information in the dialog. Feature size options are set with the DialogSetInfo function.

When the space required to display the maximum possible size has been determined, all feature names are truncated automatically, if necessary, to fit the remaining space. The name of a feature that requires less space to display its size (or that is not selected) may still be truncated under this method. To maximize performance and ensure that feature names appear complete, make feature names or display names smaller than the space available in the dialog.

The Select Subfeatures dialog cannot be displayed with a skin; it appears the same regardless of whether you have specified a skin.

See Also