Is there a way to change the color of the column in a list view instead of the whole row changing color? I have a 3 column listview and I would like the 3rd column to be a dark green but when I use the following code it is changing the whole row instead of just the one subitem.
I tried changing the SubItems(0) to SubItems(2) but then the code doesnt work at all.
Visual Basic:
Dim i As Integer
For i = 0 To ListView1.Items.Count - 1
If CInt(ListView1.Items(i).SubItems(1).Text) = 0 Then
ListView1.Items(i).SubItems(0).ForeColor = Color.Green
End If
Next
I tried changing the SubItems(0) to SubItems(2) but then the code doesnt work at all.