Skip to main content

TextEditBase.SelectAllOnGotFocus Property

Gets or sets whether to select the entire text when the editor gets focus via keyboard. This is a dependency property.

Namespace: DevExpress.Xpf.Editors

Assembly: DevExpress.Xpf.Core.v22.1.dll


public bool SelectAllOnGotFocus { get; set; }

Property Value

Type Description

true, to select the text on focus via keyboard; otherwise, false.


Set the SelectAllOnGotFocus property to true to enable automatic text selection when the editor gets focus via the keyboard. To enable text selection when the editor gets focus via mouse click, set the TextEditBase.SelectAllOnMouseUp to true.

To select all the text within the editor manually, use the TextEditBase.SelectAll method. To select only the specified amount of text, use the TextEdit.Select method.

Setting this property has no effect for TextEditBase descendants used in GridControl. The GridControl automatically selects all text in an active editors when an end user activates a cell. To select all text when an end user opens a cell by a mouse click, set DataViewBase.EditorShowMode to MouseUp or MouseUpFocused.

See Also