Back to Devexpress

BeforeFocusNodeEventArgs.CanFocus Property

windowsforms-devexpress-dot-xtratreelist-dot-beforefocusnodeeventargs.md

latest1.9 KB
Original Source

BeforeFocusNodeEventArgs.CanFocus Property

Gets or sets a value indicating whether focus is allowed to be moved.

Namespace : DevExpress.XtraTreeList

Assembly : DevExpress.XtraTreeList.v25.2.dll

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

Declaration

csharp
public bool CanFocus { get; set; }
vb
Public Property CanFocus As Boolean

Property Value

TypeDescription
Boolean

true if the focus is allowed to be moved; otherwise false.

|

Remarks

Use the CanFocus property to prohibit moving focus to particular nodes. Set this property to false for this purpose. The node to which focus is being moved can be identified via the NodeEventArgs.Node property.

Note : if a user double-clicks a parent node which cannot be focused (as a result of handling the TreeList.BeforeFocusNode event, in particular), nodes are expanded and or collapsed.

See Also

Node

OldNode

BeforeFocusNodeEventArgs Class

BeforeFocusNodeEventArgs Members

DevExpress.XtraTreeList Namespace