Upravit

Sdílet prostřednictvím


ControlCondition Table

The ControlCondition table enables an author to specify special actions to be applied to controls based on the result of a conditional statement. For example, using this table the author could choose to hide a control based on the VersionNT property.

The ControlCondition table has the following columns.

Column Type Key Nullable
Dialog_ Identifier Y N
Control_ Identifier Y N
Action Text Y N
Condition Condition Y N

 

Columns

Dialog_

An external key to the first column of the Dialog table. Combining this field with the Control_ field identifies a unique control.

Control_

An external key to the second column of the Control table. Combining this field the Dialog_ field identifies a unique control.

Action

The action that is to be taken on the control. The possible actions are shown in the following table.

Value Meaning
Default Set control as the default.
Disable Disable the control.
Enable Enable the control.
Hide Hide the control.
Show Display the control.

 

Condition

A conditional statement that specifies under which conditions the action should be triggered. This column may not be left blank. If this statement does not evaluate to TRUE, the action does not take place. If it is set to 1, the action is always applied. For information on the syntax of conditional statements, see Conditional Statement Syntax.

Remarks

If you want to hide and disable a PushButton control or CheckBox control based on a conditional statement in the Condition field of the ControlCondition table, you should use four records for each control to disable as well as hide the control. PushButton or CheckBox controls that have only been hidden can still be accessed by shortcut keys.

For example, the following records hide and disable ControlA on DialogA when the product is installed. The control will be visible and enabled when the product is not installed.

Dialog Control Action Condition
DialogA ControlA Hide Installed
DialogA ControlA Disable Installed
DialogA ControlA Show NOT Installed
DialogA ControlA Enable NOT Installed

 

Validation

ICE03
ICE06
ICE17
ICE32
ICE46
ICE79
ICE86