Gets or sets the foreground color of the row with focus.
[Visual Basic] Public Property SelectionForeColor As Color [C#] public Color SelectionForeColor {get; set;} [C++] public: __property Color get_SelectionForeColor(); public: __property void set_SelectionForeColor(Color); [JScript] public function get SelectionForeColor() : Color; public function set SelectionForeColor(Color);
A Color that represents the foreground color of a selected row. The default is the system color for active window captions (SystemColors.ActiveCaption).
The user can select an entire row by clicking its left edge when the pointer becomes an arrow.
The following example sets the foreground color of the selected row.
[Visual Basic]
Private Sub SetCurrentRowForeClr(ByVal myGrid As DataGrid, ByVal newColor As NewColor As System.Drawing.Color) myGrid.SelectionForeColor = newColor End Sub
DataGrid Class | DataGrid Members | System.WinForms Namespace | CurrentCell | SelectionBackColor | SelectionForeColor