TreeList.ShowingEditor Event
Fires before the TreeList is switched to edit mode.
Namespace: DevExpress.XtraTreeList
Assembly: DevExpress.XtraTreeList.v24.2.dll
Declaration
Event Data
The ShowingEditor event's data class is CancelEventArgs. The following properties provide information specific to this event:
Property | Description |
---|---|
Cancel | Gets or sets a value indicating whether the event should be canceled. |
Remarks
Handle the ShowingEditor
event to perform custom actions when a cell editor is about to be displayed.
For example, you can prevent the editor form being shown for a particular cell only. Use the TreeList.FocusedColumn and TreeList.FocusedNode properties to identify the focused cell for which the editor is about to be shown. Set the Cancel parameter to true to cancel the action.
Note
The ShowingEditor
event does not fire for cells within the Auto Filter Row.
Tip
You can disable the TreeList.OptionsBehavior.Editable option to prohibit users to edit all cells in the control. Use the TreeListColumn.OptionsColumn.ReadOnly option to allow users to invoke the editor to copy a value, but not to edit. The TreeListColumn.OptionsColumn.AllowEdit option allows you to prohibit users from invoking editors (even just to copy a value).
Related GitHub Examples
The following code snippet (auto-collected from DevExpress Examples) contains a reference to the ShowingEditor 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.