Hello,
I would like to change the text color in a Listview control for all the lines that are Ghosted but the problem is that the text color is changed only in the first column and not for all SubItems.
Thanks for your help,
Thierry Demoy
France
VB6
Printable View
Hello,
I would like to change the text color in a Listview control for all the lines that are Ghosted but the problem is that the text color is changed only in the first column and not for all SubItems.
Thanks for your help,
Thierry Demoy
France
VB6
You would have to change the ForeColor on each ListSubItem of the ListItem you were changing. For example:
This example just does one ListItem. You could do a loop to modify more than one.Code:Dim lngColor As Long
Dim intSubIndex As Integer
lngColor = RGB(128, 128, 128)
With ListView1
.ListItems(1).ForeColor = lngColor
For intSubIndex = 1 To .ListItems(1).ListSubItems.Count
.ListItems(1).ListSubItems(intSubIndex).ForeColor = lngColor
Next intSubIndex
.Refresh
End With
Paul