Feature Functions

InstallShield 2014 » InstallScript Language Reference

The functions below allow you to control file media and to create and process script-created feature sets.

Feature Functions

Function

Project Type

Description

FeatureAddCost

InstallScript

Specifies that the feature includes additional installation operations that should be accounted for when updating the progress bar during the installation.

Note: This function is supported only for file media. Use FeatureGetData or FeatureSetData to set the size of script-created features.

FeatureAddItem

InstallScript, InstallScript MSI

Adds a new feature to a script-created feature set.

FeatureAddUninstallCost

InstallScript

Specifies that the feature includes additional uninstallation operations that must be accounted for when updating the progress bar during uninstallation.

FeatureCompareSizeRequired

InstallScript, InstallScript MSI

Determines if enough free disk space exists for the selected features.

FeatureDialog

InstallScript, InstallScript MSI

Presents a dialog that enables end users to select features and specify a destination location.

FeatureError

InstallScript, InstallScript MSI

Returns additional error information when a feature function fails.

FeatureErrorInfo

InstallScript, InstallScript MSI

Returns additional error information when a feature function fails.

FeatureFileEnum

InstallScript, InstallScript MSI

Builds a list of the files in a component associated with the specified feature.

FeatureFileInfo

InstallScript, InstallScript MSI

Retrieves information on file in the file media that is referenced within the function.

FeatureFilterLanguage

InstallScript, InstallScript MSI

Enables and disables filtering based on language.

FeatureFilterOS

InstallScript, InstallScript MSI

Enables and disables filtering based on operating system (OS).

FeatureGetCost

InstallScript, InstallScript MSI

Retrieves the total space, in kilobytes (KB), required on the target drive for the specified feature.

FeatureGetCostEx supersedes this function.

FeatureGetCostEx

InstallScript, InstallScript MSI

Retrieves the cost of the specified feature (in bytes) using the nvCostHigh and nvCostLow parameters.

FeatureGetData

InstallScript, InstallScript MSI

Retrieves information about a feature.

FeatureGetItemSize

InstallScript, InstallScript MSI

Determines the size of a specified feature.

FeatureGetTotalCost

InstallScript, InstallScript MSI

Determines the total space required for the feature installations and uninstallations that have been specified.

FeatureGetCostEx supersedes this function.

FeatureInitialize

InstallScript

Supported only for compatibility with scripts created in earlier versions of InstallShield. It is recommended that you avoid using multiple file media libraries in InstallShield.

FeatureIsItemSelected

InstallScript, InstallScript MSI

Determines if the specified feature has been selected by the end user.

FeatureListItems

InstallScript, InstallScript MSI

Creates a list of the features in a file media library or a script-created feature set.

FeatureLoadTarget

InstallScript

Called automatically during the initialization of any installation for which a valid log file exists.

FeatureMoveData

InstallScript

Transfers and decompresses files associated with selected features in the file media.

FeaturePatch

InstallScript

Called only in installations that use differential media. This function causes the next call to FeatureTransferData or FeatureMoveData to reinstall all features that are already installed when FeatureTransferData is called, including all of the maintenance/uninstallation feature's files except for Data1.hdr, Data1.cab, and Layout.bin.

FeatureReinstall

InstallScript, InstallScript MSI

Configures the setup so that the next call to FeatureTransferData performs the file transfer that was specified the last time the setup was run.

FeatureRemoveAll

InstallScript, InstallScript MSI

Configures the setup so that the next call to FeatureTransferData uninstalls the setup.

FeatureRemoveAllInLogOnly

InstallScript

Called during an update installation to force the removal of all features that are not in the current media but were installed previously, as recorded in the setup log file.

FeatureRemoveAllInMedia

InstallScript

Used during a maintenance installation to force the removal of all features that are in the current media and were installed previously. This function is generally called when the user selects the Remove option on the SdWelcomeMaint dialog.

FeatureRemoveAllInMediaAndLog

InstallScript

Called during an update installation to force the removal of all features that were installed previously—both those that are in the current media, and those that are not in the current media but are recorded in the setup log file.

FeatureSaveTarget

InstallScript, InstallScript MSI

Retrieves the current values of all text substitutions used by the installation project and stores them in the installation log file.

FeatureSelectItem

InstallScript, InstallScript MSI

Selects or deselects features.

FeatureSelectNew

InstallScript

Sets the selection status of all new features to either selected or unselected.

FeatureSetData

InstallScript, InstallScript MSI

Sets properties and data for the specified feature.

FeatureSetTarget

InstallScript, InstallScript MSI

Specifies a user-defined variable for a file media library.

FeatureSetupTypeEnum

InstallScript, InstallScript MSI

Enumerates the setup types associated with the specified file media library.

FeatureSetupTypeGetData

InstallScript, InstallScript MSI

Retrieves data associated with a specified setup type that has been created in the InstallShield interface.

FeatureSetupTypeSet

InstallScript, InstallScript MSI

Selects all features associated with the specified setup type.

FeatureSpendCost

InstallScript

Updates the progress bar for a certain amount of cost that has been spent by an event external to the installation.

FeatureSpendUninstallCost

InstallScript

Updates the progress bar for a certain amount of uninstallation cost that has been spent by an event external to the installation.

FeatureStandardSetupTypeSet

InstallScript, InstallScript MSI

Sets the current setup type to the standard setup type specified by nSetupType.

FeatureTotalSize

InstallScript, InstallScript MSI

Calculates the total size, in bytes, of selected features and subfeatures.

FeatureTransferData

InstallScript, InstallScript MSI (if the InstallScript user interface (UI) style is the traditional style, which uses the InstallScript engine as an external UI handler)

Important: This function does not apply to InstallScript MSI projects in which the InstallScript UI style is the new style (which uses the InstallScript engine as an embedded UI handler). To learn more, see Using the InstallScript Engine as an External vs. Embedded UI Handler for InstallScript MSI Installations.

In an event-based script, installs or uninstalls features appropriately based on their selection state and whether they are currently installed.

FeatureUpdate

InstallScript

Configures the installation so that the next call to FeatureTransferData or FeatureMoveData reinstalls all features that are already installed.

FeatureValidate

InstallScript

Validates the password of the file media library or of a specified feature.

SdSetupType

InstallScript, InstallScript MSI

Displays a dialog that enables end users to select one of the three standard setup types: Typical, Compact, or Custom.

SdSetupType2

InstallScript, InstallScript MSI

Displays a dialog that enables the end user to select one of the two standard setup types: Typical or Custom.

SdSetupTypeEx

InstallScript MSI

Displays a dialog that enables the end user to select the setup type when you specify setup types beyond Complete and Custom.