Dialog control conditions

Control conditions allow you to dynamically update the enabled/disabled state of a control, based on a conditional expression that is automatically re-evaluated whenever one of its parts changes.

If you define a control condition for a control, it will be evaluated just before the parent dialog is shown.

The condition is also automatically re-evaluated if any of its parts changes while the parent dialog box is open; this allows dynamic control state changes. For example, this is how the Next PushButton control is re-enabled in the predefined LicenseDlg dialog box when the user clicks the I agree... CheckBox control (and disabled again if the I agree... box is cleared): it is linked to the UILicenseAgreed variable that is set or reset by the I agree... check box.

Tip: You can also change a control's visibility or enabled state by using a Set Window State action as an event handler elsewhere in the same dialog or as an action in any action sequence that runs while the parent dialog box is open.

Method Remarks
Control condition attribute Control conditions update the enabled/disabled state of their control with a single condition. InstallMate automatically re-evaluates the condition whenever a referenced variable changes. This allows for dynamic updating of the control's state.
Set Window State action Set Window State actions can be executed in dialog event handlers or as part of action sequences. They can show, hide, enable, disable, minimize, maximize, make read-only, make read/write or send messages to the control (or any other installer window). Set Window State actions may or may not be conditional, just like any installer action.