Returns or sets a value that determines if a user can edit labels of Node objects in a ListView or TreeView control.
object.LabelEdit[ = integer ]
The parts of the LabelEdit property syntax are described in the following table.
Part | Description |
---|---|
object | An object expression that evaluates to an object. |
integer | An integer that determines whether the label of a Node object can be edited, as specified in Settings. |
The settings for integer are described in the following table.
Value | Description |
---|---|
0 | (Default) Automatic. The BeforelabelEdit event is generated when the user clicks the label of a selected node. |
1 | Manual The BeforelabelEdit event is generated only when the StartLabelEdit method is invoked. |
Label editing of an object is initiated when a selected object is clicked (if the LabelEdit property is set to Automatic). That is, the first click on an object will select it; a second (single) click on the object will initiate the label editing operation.
The LabelEdit property, in combination with the StartLabelEdit method, allows you to programmatically determine when and which labels can be edited. When the LabelEdit property is set to 1, no label can be edited unless the StartLabelEdit method is invoked.