Saturday, March 29, 2014

Check And Uncheck DataGridView Cell

If DataGridView1.Rows(e.RowIndex).Cells(e.ColumnIndex).Value = "P" Then
                DataGridView1.Rows(e.RowIndex).Cells(e.ColumnIndex).Value = ""
            Else
                DataGridView1.Rows(e.RowIndex).Cells(e.ColumnIndex).Style.Font = New Font("Wingdings 2", 14, FontStyle.Bold)
                DataGridView1.Rows(e.RowIndex).Cells(e.ColumnIndex).Value = "P"
            End If

No comments: