SdAskOptionsList

InstallShield 2014 » InstallScript Language Reference

Project: This information applies to the following project types:

InstallScript
InstallScript MSI

The SdAskOptionsList function creates a dialog that displays a list of features for a custom installation.

Syntax

SdAskOptionsList ( szTitle, szMsg, szFeatures, nStyle );

Parameters

SdAskOptionsList Parameters

Parameter

Description

szTitle

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

szMsg

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

szFeatures

Specifies the name of the feature that contains the subfeatures to be displayed. The subfeatures are preceded by check boxes or option buttons. To display all top-level features, pass a null string (“”) in this parameter.

SdAskOptionsList searches for the requested feature(s) in the file media library or script-created feature set specified by the system variable MEDIA.

nStyle

Specifies whether the end user's selection is limited. Pass one of the following predefined constants in this parameter:

EXCLUSIVE—Allows the end user to select only one item from the list. Do not use EXCLUSIVE mode if any of szFeatures' subfeatures are required features.
NONEXCLUSIVE—Allows the end user to select more than one item from the list, including multiple non-contiguous selections. Also displays two buttons—Select All and Clear All—which allow selection of all options or clearing of all selections.

Return Values

SdAskOptionsList Return Values

Return Value

Description

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.
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 SdAskOptionsList.
SdAskOptionsList 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 (Data1.cab).

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 SdAskOptionsList to get end-user selections.
4. Assign to MEDIA the value that you saved in step 1. You must do this before calling FeatureTransferData.

See Also