Kod:
Buton 1 kodlarını bunlarla değiştiriniz.
Dim satır = DataGridView1.Rows.Count - 1
Dim x As Integer = 0
While x < satır - 2
For y As Integer = (satır - 2) To (x + 1) Step -1
If DataGridView1.Rows(x).Cells(0).Value.ToString() = DataGridView1.Rows(y).Cells(0).Value.ToString() Then
DataGridView1.Rows.Remove(DataGridView1.Rows(y))
satır -= 1
End If
Next
x += 1
End While