SdLicense

InstallShield 2014 » InstallScript Language Reference

Project: This information applies to the following project types:

InstallScript
InstallScript MSI

The SdLicenseEx function supersedes the SdLicense function.

The SdLicense function displays a dialog that contains a license agreement in a multi-line edit field. The license agreement is stored in a text file identified in the parameter szLicenseFile.

The end user can scroll up and down to read the agreement. The end user must choose either the Yes, No, or—if enabled—Back button. Because this is usually the first dialog that you would display, you might want to disable the Back button. If the user selects Yes, the installation continues. If the user selects No, the installation displays the ExitSetup dialog.

Syntax

SdLicense ( szTitle, szMsg, szQuestion, szLicenseFile );

Parameters

SdLicense Parameters

Parameter

Description

szTitle

Specify the title of the dialog. To display the default title (“Software License Agreement”), pass a null string (“”) in this parameter.

szMsg

Specify the message to display in the static text field above the multi-line edit field. To display the default instructions, pass a null string (“”) in this parameter.

szQuestion

Specify the text to display in the static text field below the multi-line edit field. You would likely place a question here, to which the user should respond by selecting either Yes and No. To display the default instructions, pass a null string (“”) in this parameter.

szLicenseFile

Specify the name of the ANSI text file that contains the license agreement. This file must be added to the appropriate language folder in the Support Files/Billboards view. You can also specify szLicenseFile by entering the fully qualified name, in quotation marks, or a UNC path.

Note: This file must be a text file (.txt).

Return Values

SdLicense Return Values

Return Value

Description

YES (1)

The end user selected the Yes button.

BACK (12)

Indicates that the user selected the Back button.

Note: This function cannot return NO because if the end user clicks the No button, the ExitSetup dialog is displayed.

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.

See Also