Do you know how to put a color font the data in the ListView please.
So, I want the 1st row with red font, the 2nd row with blue color, 3rd row red again and so on.
Set the ForeColor property of each item. You'll need to set the UseItemStyleForSubItems property to True or else only the first column will be coloured.
'Dim Itema = New ListViewItem
'For Each Itema In ListView1.Items
' If (Itema.Index Mod 2) = 0 Then
' 'Itema.BackColor = Color.Red
' Itema.ForeColor = Color.Red
' Else
' 'Itema.BackColor = Color.Yellow
' Itema.ForeColor = Color.Yellow
' End If
'Next
I think we've already discussed this in another thread but you should call BeginUpdate first and EndUpdate last. Otherwise the ListView will be redrawn after each item is changed or added. The continual redrawing makes things very slow.