我只想在单元格中的值是certin值时显示图例,我正在使用此
Private Sub dgDeliverys_DataBindingComplete(sender As System.Object, e As System.Windows.Forms.DataGridViewBindingCompleteEventArgs) Handles dgDeliverys.DataBindingComplete
For Each dr As DataGridViewRow In Me.dgDeliverys.Rows
'condition for each row based on cell's input is put here
If dr.Cells("isNotFound").Value = True Then
dr.DefaultCellStyle.BackColor = Color.Red
dr.DefaultCellStyle.ForeColor = Color.White
End If
Next
End Sub
现在我的网格当时只有几行。但它似乎导致形式冻结,任何想法?