Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Listview row colors

Status
Not open for further replies.

Lxmm

Programmer
May 10, 2005
32
GB
Hi,
Is there a way to change the back color of certain rows in Listview control in vb.net?
Thanks
 
yes

set the listview.listitems(i).backcolor and listview.listitems(i).forecolor properties.

you can set them to a member of system.drawing.colors.

For instance:

Code:
ListView1.ListItems(1).BackColor = System.Drawing.Color.Crimson
ListView1.ListItems(1).ForeColor = System.Drawing.Color.Black


__________________
code is enduring
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top