DataGridView Selected Row
I have a DataGridView control with the FullRowSelect SelectionMode, chosen (MultiSelect=False). So I select a row and all cells in that row go blue.
I don't want the left-hand cell to go blue when I select a row, as this cell is colour-coded (background colour of cell is either red or green and I want the cell to stay that colour even when selected)
Does anyone have any idea which event to handle to prevent this?
Thanks
Re: DataGridView Selected Row
ok - turned out to be straighforward.
Whenever you set:
row.Cells["MyColumn"].Style.BackColor = Color.Green;
at the same time set:
row.Cells["MyColumn"].Style.SelectionColor = Color.Green;