VB2005 - Multicolor Listbox?

Rexyss

Member
Joined
Jan 3, 2008
Messages
12
Programming Experience
Beginner
Is it possible to have more then one color text in a listbox??

I have a listbox and want something like this: (Text Color)
(RED) -456545
(Blue) 121212
(Blue) 454574
(RED) -147454

How to write it? Tryed,but it changes the color for all text lines..
 
You have to draw the items yourself, this is easy to do. Set DrawMode=OwnerDrawFixed and handle the DrawItem event. Example
 
Back
Top