Share via


Checkboxes User Interface Dialog Box

Checkboxes dialog boxes are used to present up to four choices to a user and return the values of those choices during installation. Three Checkboxes dialog boxes are available: Checkboxes (A), Checkboxes (B), and Checkboxes (C). These three dialog boxes are identical; each can be added only once for each deployment project.

The dialog boxes contain four check boxes with associated labels, plus additional labels to present information to the user. The text for these labels is specified at design time in the Properties window. Additional properties are provided for each check box to control visibility, to set a default value, and to return a value.

The following illustration shows a typical Checkboxes dialog box, as it would appear during installation.

Checkboxes dialog box

Deployment UI splash screen

Properties

The following properties are available for the Checkboxes dialog box.

Property

Description

BannerBitmap

Specifies a bitmap or JPEG image to be displayed in the banner area. In the above illustration, the default bitmap is shown. For more information, see BannerBitmap Property.

BannerText

Specifies the text to be displayed in the banner area. In the above illustration, this corresponds to "This is the banner text."

BodyText

Specifies the text to be displayed above the check boxes. In the above illustration, this corresponds to "This is the body text."

Checkbox1Label

Specifies the text to be displayed next to the first check box. In the above illustration, this corresponds to "First selection".

Checkbox1Property

Specifies a property name used to retrieve the value (Checked or Unchecked) of the first check box. This property can be used in conditions.

Checkbox1Value

Specifies the initial value (Checked or Unchecked) of the first check box.

Checkbox1Visible

Specifies whether the first check box is visible or hidden. This should be set to true for a dialog box that displays one or more check boxes.

Checkbox2Label

Specifies the text to be displayed next to the second check box. In the above illustration, this corresponds to "Second selection".

Checkbox2Property

Specifies a property name used to retrieve the value (Checked or Unchecked) of the second check box. This property can be used in conditions.

Checkbox2Value

Specifies the initial value (Checked or Unchecked) of the second check box.

Checkbox2Visible

Specifies whether the second check box is visible or hidden. This should be set to true for a dialog box that displays two or more check boxes, or to false for a dialog box that displays a single check box.

Checkbox3Label

Specifies the text to be displayed next to the third check box. In the above illustration, this corresponds to "Third selection".

Checkbox3Property

Specifies a property name used to retrieve the value (Checked or Unchecked) of the third check box. This property can be used in conditions.

Checkbox3Value

Specifies the initial value (Checked or Unchecked) of the third check box.

Checkbox3Visible

Specifies whether the third check box is visible or hidden. This should be set to true for a dialog box that displays three or more check boxes, or to false for a dialog box that displays two or fewer check boxes.

Checkbox4Label

Specifies the text to be displayed next to the fourth check box. In the above illustration, this corresponds to "Fourth selection".

Checkbox4Property

Specifies a property name used to retrieve the value (Checked or Unchecked) of the fourth check box. This property can be used in conditions.

Checkbox4Value

Specifies the initial value (Checked or Unchecked) of the fourth check box.

Checkbox4Visible

Specifies whether the fourth check box is visible or hidden. This should be set to true for a dialog box that displays four check boxes, or to false for a dialog box that displays three or fewer check boxes.

Controlling the Appearance of the Checkboxes Dialog Box

Several properties control how the Checkboxes dialog box will appear to the user during installation.

  • The BannerBitmap property controls the image that appears in the upper right corner of the dialog box. The position and size of the image is fixed.

    Tip

    For a consistent user interface, the same image should be used for all dialog boxes in an installer.

  • The BannerText property controls the text that is displayed in the banner across the top of the dialog box. The position, size, and font size are fixed. The text will wrap but cannot be more than two lines.

  • The BodyText property controls the text that appears just below the banner portion of the dialog box. The position and font size are fixed. The text will wrap but cannot be more than four lines.

  • The CheckboxNLabel properties control the text in the check-box labels. The position, size, and font size are fixed, and the text will not wrap.

    Tip

    For dialog boxes that may be localized, allow extra space for the text expansion. A word in one language may translate into a much longer word in another language, causing the text to be cut off.

Retrieving User Choices with Checkboxes Dialog Box Properties

When the installer containing the Checkboxes dialog box is run, the user can change the value of any visible check boxes; you can then use that choice to control another phase of installation.

For example, you might create a Checkboxes dialog box that gives the user a choice of installing two optional files, File A and File B. In this case, you would set the Checkbox1Label property to "Install File A" and the Checkbox2Label property to "Install File B". You would also set the Checkbox3Visible and Checkbox4Visible properties to false, since you only need two check boxes.

If you thought that users would usually want to install File A, you could set the Checkbox1Value property to Checked so that it would be checked by default.

In the File System Editor, you would set the Condition property for File A to the value of the Checkbox1Property property, and the Condition property for File B to the value of the Checkbox2Property property.

During installation, the Condition property for each file will be evaluated. If the user checks the check box, the condition will evaluate to true and the file will be installed; otherwise, it will not be installed.

See Also

Concepts

Installation Dialog Box Restrictions

Other Resources

User Interface Management in Deployment

Deployment Dialog Boxes

Launch Condition Management in Deployment