Conditions in which an item will display a check box.

Usage

Set_Property(OLECtrlEntID, "OLE.CheckBoxConditions", Array)

Values

Array has the following structure:

PosNameTypeDescription
<1>Left Check BoxFormatted StringThe condition in which a check box is displayed on the left hand side of an item
<2>Right Check BoxFormatted StringThe condition in which a check box is displayed on the right hand side of an item

Remarks

The CheckBoxConditions property allows you to automate which items display a check box. You provide a specially formatted condition statement telling the control what state the item must be in to show the check box. When the SRP Tree Control displays an item, it compares the item to the given condition and if true, displays the check box.

This property has two fields. The first field establishes the condition in which a check box will appear to the item's left. The second field establishes the condition in which a check box will appear to the item's right. The following table shows the results of the conditions:

Is Left Condition True?Is Right Condition True?Result
NoNoNo Check Boxes
YesNoCheck Box on Left
NoYesCheck Box on Right
YesYesCheck Box on Left

It may help to visualize the two fields as a case statement:

Begin Case
Case Left
Condition Show
LeftCheckBox()
Case RightCondition
ShowRightCheckBox()
End Case

 

This property is overridden by the ItemCheckBox property value. In other words, the conditions are only evaluated as long as the ItemCheckBox property is 0.

For more information on using conditions, see the Conditions tutorial in the Using SRP OLE Tree section.

Example

// Display left hand check boxes for all items  
Conditions = ""  
Conditions<1> = 1  
Set_Property(@Window:".OLE_TREE", "OLE.CheckBoxConditions", Conditions)  

// Display right hand check boxes for items with no children  
Conditions = ""  
Conditions<2> = "Not(HasChildren)"  
Set_Property(@Window:".OLE_TREE", "OLE.CheckBoxConditions", Conditions)

See Also

ItemCheckBoxDragConditionDropConditionImageConditionsOnItemCheck

  • No labels