TreeList.FocusedNodeChanged Event
Fires when focus moves from one node to another.
Namespace: DevExpress.XtraTreeList
Assembly: DevExpress.XtraTreeList.v24.1.dll
NuGet Packages: DevExpress.Win.Navigation, DevExpress.Win.TreeList
Declaration
[DXCategory("Property Changed")]
public event FocusedNodeChangedEventHandler FocusedNodeChanged
Event Data
The FocusedNodeChanged event's data class is FocusedNodeChangedEventArgs. The following properties provide information specific to this event:
Property | Description |
---|---|
Node | Gets the current Tree List node. Inherited from NodeEventArgs. |
OldNode | Gets the previously focused Tree List node. |
Remarks
The FocusedNodeChanged event fires when focus moves from node to node for the following reasons:
- A user moves focus to a node.
- The TreeList.FocusedNode property is changed in code.
- Focus moves to the added node when you use the TreeList.AppendNode method.
- Focus moves to the focused node’s parent after the parent node is collapsed.
- The focused node is removed from the Tree List control.
Handle the TreeList.BeforeFocusNode event to specify whether a particular node can receive focus.
You can use the FocusedRowChanged and TreeList.SelectionChanged events interchangeably in single selection mode (see treeList.OptionsSelection.MultiSelect).
Related GitHub Examples
The following code snippets (auto-collected from DevExpress Examples) contain references to the FocusedNodeChanged event.
Note
The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.