TreeList.FocusedNodeChanged Event

Fires immediately after changing the focused node.

Namespace: DevExpress.XtraTreeList

Assembly: DevExpress.XtraTreeList.v20.1.dll


[DXCategory("Property Changed")]
public event FocusedNodeChangedEventHandler FocusedNodeChanged
<DXCategory("Property Changed")>
Public Event FocusedNodeChanged As FocusedNodeChangedEventHandler

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.


The FocusedNodeChanged event fires when focus moves from node to node for the following reasons:

  • Focus is moved to another node by an end-user or by changing the TreeList.FocusedNode property value.
  • Focus is moved to the added node when using the TreeList.AppendNode method.
  • Focus is moved to the focused node's parent as a result of the collapse of the parent node.
  • The focused node is removed from the Tree List control.

You can respond to all the mentioned focused node changes by handling the FocusedNodeChanged event. Write a handler for this event if your application's appearance or behavior depends on the currently focused node. For instance, you may want to display the information from the focused node, and therefore need to update this information when the focused node changes.

The Tree List control enables you to specify whether a particular node can obtain focus. Handle the TreeList.BeforeFocusNode event for this purpose.

See Also