hi..
can anyone help me about my problem in listview, i'm trying to delete listview item that's already in my data table, the problem is every time the loop comes to last item of my listview i got an error. Error Message = "Specified argument was out of range of valid values. Not valid for ‘Display Index’"
this is my sample code:
For i = 0 To ListView1.Items.Count - 1
For Each Row As DataRow In Table.Rows
If Me.ListView1.Items(i).SubItems(2).Text().ToString = Row("UserID") Then
Me.ListView1.Items.RemoveAt(i)
End If
Next
Next i
thank you..