A newer version of this page is available. Switch to the current version.

GridView.FocusRectStyle Property

Gets or sets a value specifying how the focus rectangle is painted.

Namespace: DevExpress.XtraGrid.Views.Grid

Assembly: DevExpress.XtraGrid.v19.2.dll


public virtual DrawFocusRectStyle FocusRectStyle { get; set; }
Public Overridable Property FocusRectStyle As DrawFocusRectStyle

Property Value

Type Default Description


A DrawFocusRectStyle enumerator value.


This example shows how to paint the focused cell using the same appearance as the entire focused row:


// Make the grid read-only.
gridView1.OptionsBehavior.Editable = false;
// Prevent the focused cell from being highlighted.
gridView1.OptionsSelection.EnableAppearanceFocusedCell = false;
// Draw a dotted focus rectangle around the entire row.
gridView1.FocusRectStyle = DevExpress.XtraGrid.Views.Grid.DrawFocusRectStyle.RowFocus;
See Also