DataGrid.HeaderForeColor Property

 

Gets or sets the foreground color of headers.

Namespace:   System.Windows.Forms
Assembly:  System.Windows.Forms (in System.Windows.Forms.dll)

public Color HeaderForeColor { get; set; }

Property Value

Type: System.Drawing.Color

A Color that represents the foreground color of the grid's column headers, including the column header text and the plus/minus glyphs. The default is ControlText color.

The following code example sets the foreground color of the grid's column headers.

Private Sub SetHeaderForeClr(ByVal myGrid As DataGrid, ByVal newColor As System.Drawing.Color)
    myGrid.HeaderForeColor = newColor
 End Sub

.NET Framework
Available since 1.1
Return to top
Show: