datagridview row back color
-
foreach (DataGridViewRow dr in dgproducts.Rows) { if (Convert.ToInt32(dr.Cells[9].Value) < Convert.ToInt32(dr.Cells[6].Value)) { ## //i need to color this row here } } ## i need to colour the particular row at that point of the loop i cant find anything like in that intellisense and sub-intellisense maybe am not checking well. any help plz
-
foreach (DataGridViewRow dr in dgproducts.Rows) { if (Convert.ToInt32(dr.Cells[9].Value) < Convert.ToInt32(dr.Cells[6].Value)) { ## //i need to color this row here } } ## i need to colour the particular row at that point of the loop i cant find anything like in that intellisense and sub-intellisense maybe am not checking well. any help plz
-
DataGridView.Rows.DefaultCellStyle.BackColor
will do that.It's not necessary to be so stupid, either, but people manage it. - Christian Graus, 2009 AD