I'm getting an error when I have rows deleted. The way I'm doing it is once a row is deleted, I go back to the previous row and check to make sure and then continues. I'm assuming that the DataTable need to be re-index? I've tried to add AcceptChanges() at the end and it doesn't work too.
Down below is my code:
For i = 0 to dt.Rows.Count - 1
If dt.Rows(i)("Isbn").StartsWith("B") Then
dt.Rows(i).Delete()
i -= 1
End If
Next