Advertisement
Guest User

Untitled

a guest
Apr 24th, 2014
37
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.42 KB | None | 0 0
  1. `Private Sub dgCorpResults_CurrentCellChanged(ByVal sender As Object, ByVal e As
  2. System.Windows.Forms.DataGridViewCellFormattingEventArgs) Handles dgvMatrix.CellFormatting
  3.  
  4.  
  5. Try
  6. For Each cell As DataGridViewCell In dgvMatrix.Rows(e.RowIndex).Cells
  7. cell.Style.BackColor = Color.Red
  8. Next
  9. Catch ex As Exception
  10. End Try
  11.  
  12. If value=0 Then
  13. cell.Style.BackColor = Color.Red
  14. Else
  15. cell.Style.BackColor = Color.LightGreen
  16. End If
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement