ITreeControl.Locked

Syntax

Locked: Boolean;

Locked: boolean;

Description

The Locked property determines whether it is possible to change selection and edit element text in the component.

Comments

Available values:

NOTE. This property locks selection change and elements editing in the component only via mouse click. The possibility to change selection and edit elements text using the corresponding ITreeListNode.Text and ITreeListNode.ColumnText properties and methods in the kernel is available at any values of the Locked property.

NOTE. Editing of elements text is not available if the ITreeControl.ReadOnly property is set to True by default.

Example

Executing the example requires that the from contains the Button component named Button1 and the TreeList component named TreeList1 (for Fore.NET example use the TreeListNet component named TreeListNet1.

Add links to the system assemblies:

Sub Button1OnClick(Sender: Object; Args: IMouseEventArgs);
Begin
    
TreeList1.Locked := 
False;
    TreeList1.ReadOnly := 
False;
End Sub Button1OnClick;

Imports System.Windows.Forms;
Imports Prognoz.Platform.Forms.Net;

Private Sub button1_Click(sender: System.Object; e: System.EventArgs);
Begin
    
TreeListNet1.Locked := False;
    TreeListNet1._ReadOnly := 
False;
End Sub;

After executing the example, after the button is clicked, elements text editing and selection change are allowed for the TreeList component.

See also:

ITreeControl | ITreeControl.ReadOnly