I want to change the backcolor of a headercell in datagridview row .So how can i do that in code C#?
views:
615answers:
3
A:
I found it lolz
dataGridView1.Rows[index].HeaderCell.Style.BackColor = System.Drawing.Color.Red;
But now can anyone tell me how do i change font properties of the text named as value of the headercell like " headercell.value "
Mobin
2009-10-19 15:03:26
A:
To change the font properties of a specified header cell you can try:
dataGridView1.Columns[index].HeaderCell.Style.Font = new Font("Arial", 24, , FontStyle.Bold);
Robert Höglund
2009-10-19 18:13:00
A:
you can try this
dataGridView1.EnableHeadersVisualStyles = false; dataGridView1.Columns[index].HeaderCell.Style.Font = new Font("Arial", 24, , FontStyle.Bold);
Essar Patel
2010-08-30 08:00:53