aspnet-devexpress-dot-web-dot-gridviewstyles-0a228c08.md
Specifies the appearance of the selected data row.
Namespace : DevExpress.Web
Assembly : DevExpress.Web.v25.2.dll
NuGet Package : DevExpress.Web
public GridViewDataRowStyle SelectedRow { get; }
Public ReadOnly Property SelectedRow As GridViewDataRowStyle
| Type | Description |
|---|---|
| GridViewDataRowStyle |
Style settings that specify the selected row appearance.
|
Enable row selection and specify the SelectedRow property to define the appearance of the selected row.
The style settings of the selected row are not in effect when row selection is disabled.
The SelectedRow property allows you to specify the appearance of the selected row in markup and in a CSS class.
<dx:ASPxGridView ID="ASPxGridView1" >
<%--...--%>
<Styles>
<SelectedRow BackColor="Brown" ForeColor="Yellow" >
</SelectedRow>
</Styles>
</dx:ASPxGridView>
#ASPxGridView1 .selectedRowStyle td{
background-color: Brown;
}
<dx:ASPxGridView ID="ASPxGridView1" >
<%--...--%>
<Styles>
<SelectedRow CssClass="selectedRowStyle" />
</Styles>
</dx:ASPxGridView>
See Also