Using Advanced UI and Suite/Advanced UI Formatted Expressions to Dynamically Configure Command Lines

InstallShield 2019

Project • This information applies to the following project types:

Advanced UI
Suite/Advanced UI

Edition • The Advanced UI project type is available in the Professional edition of InstallShield. The Suite/Advanced UI project type is available in the Premier edition of InstallShield. For information about the differences between these two project types, see Advanced UI Projects vs. Suite/Advanced UI Projects.

InstallShield lets you use Advanced UI and Suite/Advanced UI formatted expressions to dynamically configure the command lines that the Advanced UI or Suite/Advanced UI installation uses to launch the Advanced UI or Suite/Advanced UI packages. The formatted expressions can consist of property names, environment variable references, and other special strings; at run time, the installation expands the values of these expressions.

In some scenarios, you can use a single Advanced UI or Suite/Advanced UI formatted expression to configure most or all of your packages; in other scenarios, each package requires a different Advanced UI or Suite/Advanced UI formatted expression.

To learn about the syntax that is available for these expressions, see Using Formatted Expressions that Advanced UI and Suite/Advanced UI Installations Resolve at Run Time.

The following sample scenarios explain how to use an Advanced UI or Suite/Advanced UI property as your formatted expression to pass values to packages in the installation.

Using an Advanced UI or Suite/Advanced UI Property to Pass the Same Value to Packages in the Advanced UI or Suite/Advanced UI Installation

When you are creating an Advanced UI or Suite/Advanced UI installation, you may need to use an Advanced UI or Suite/Advanced UI property to set a Windows Installer property to change how each .msi package is installed. For example, if you are creating a multilanguage installation, you may need to select a language transform that controls which language is installed. In this particular example, the language (and hence, the property value) would probably be the same for each package in your Advanced UI or Suite/Advanced UI project.

In an Advanced UI project, the Advanced UI or Suite/Advanced UI property ISSelectedLanguage property identifies the language that is used for the Advanced UI or Suite/Advanced UI installation. If you configure your release to allow end users to select the language, the InstallationLanguage wizard page prompts end users for the language; the installation sets the ISSelectedLanguage property to a string that contains the decimal language identifier of the language that they selected.

In order to run the .msi packages in the Advanced UI or Suite/Advanced UI project in the appropriate language, include the following in the value that you enter for the command line settings for each .msi package:

TRANSFORMS="[ISPREREQDIR]\[ISSelectedLanguage].mst"

The .mst file should be in the same folder as the .msi package.

Use the following syntax for your command line settings of Basic MSI .exe packages:

/L[ISSelectedLanguage]

Using an Advanced UI or Suite/Advanced UI Property to Pass Different Values to Packages in the Advanced UI or Suite/Advanced UI Installation

You may want to use an Advanced UI or Suite/Advanced UI property to pass different property values to each or some packages in your Advanced UI or Suite/Advanced UI installation. For example, you may want to allow end users to override INSTALLDIR to different locations, one for each package. In this example, the value of INSTALLDIR could be different for each package.

When you add the predefined BrowseFolder wizard page to your project for one of the packages in your Advanced UI or Suite/Advanced UI project, InstallShield automatically adds the following to the package’s command line settings for the install operation in the Packages view:

INSTALLDIR="[ISInstallDir_PackageDisplayName]"

You can override that command line if appropriate. If the package is an .msi package, that command line sets the package’s INSTALLDIR value to the path that the end user selected on the BrowseFolder wizard page for that package.

If the package is a Basic MSI or InstallScript MSI .exe package, change the default command lines to use this syntax:

/v"INSTALLDIR=\"[ISInstallDir_PackageDisplayName]\""

See Also