NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

DataGrid.SelectionBackColor

Gets or sets the background color of the selected row.

[Visual Basic]
Public Property SelectionBackColor As Color
[C#]
public Color SelectionBackColor {get; set;}
[C++]
public: __property Color get_SelectionBackColor();
public: __property void set_SelectionBackColor(Color);
[JScript]
public function get SelectionBackColor() : Color;
public function set SelectionBackColor(Color);

Property Value

A Color that represents the background color of the row with focus. The default is the system color for active window captions (SystemColors.ActiveCaption).

Remarks

The user can select an entire row by clicking at the left edge when the pointer becomes an arrow.

Example [Visual Basic]

The following example sets the background color of the selected row.

[Visual Basic]

Private Sub SetCurrentRowBackClr(ByVal myGrid As DataGrid, ByVal newColor As System.Drawing.Color)
   Set myGrid.SelectionBackColor = System.Drawing.Color.Red
End Sub

See Also

DataGrid Class | DataGrid Members | System.WinForms Namespace | CurrentCell | SelectionForeColor