Back to Devexpress

TreeListOptionsBehavior.AllowExpandOnDblClick Property

windowsforms-devexpress-dot-xtratreelist-dot-treelistoptionsbehavior-28af697f.md

latest2.9 KB
Original Source

TreeListOptionsBehavior.AllowExpandOnDblClick Property

Gets or sets whether a user can expand or collapse a node by double clicking it.

Namespace : DevExpress.XtraTreeList

Assembly : DevExpress.XtraTreeList.v25.2.dll

NuGet Packages : DevExpress.Win.Navigation, DevExpress.Win.TreeList

Declaration

csharp
[DefaultValue(true)]
[XtraSerializableProperty]
public virtual bool AllowExpandOnDblClick { get; set; }
vb
<DefaultValue(True)>
<XtraSerializableProperty>
Public Overridable Property AllowExpandOnDblClick As Boolean

Property Value

TypeDefaultDescription
Booleantrue

true if a double-click on a node expands or collapses it; otherwise, false.

|

Property Paths

You can access this nested property as listed below:

Object TypePath to AllowExpandOnDblClick
TreeList

.OptionsBehavior .AllowExpandOnDblClick

|

Remarks

Activate the AllowExpandOnDblClick option to allow users to expand or collapse a node by double clicking it. If the TreeList control is editable, users can double click the node’s indicator cell to toggle its expanded state.

If data editing is disabled, users can double click any cell within a node to expand or collapse it:

csharp
// Disable data editing in the TreeList.
treeList1.OptionsBehavior.Editable = false;
// Enable expand/collapse on double click.
treeList1.OptionsBehavior.AllowExpandOnDblClick = true;

The following animation shows the result:

See the following help topic for more information: End-User Capabilities - Expand and Collapse Nodes.

See Also

Expand

Collapse

TreeListOptionsBehavior Class

TreeListOptionsBehavior Members

DevExpress.XtraTreeList Namespace