Subject: Re: MS Visual C++ 1.5, list boxes

From: "K. Muthu Kumar" <pearl@PearlPC>
Date: Wed, 15 Feb 1995 22:57:49 GMT

The only solution is to use Owner draw listbox. Associate a COLORREF value
to each item using
SetItemData method. In DrawItem method, draw the item using the color (
GetItemData).

I hope this tip helps.

>Path: btcase!bt!pipex!uknet!ukc!eagle.ukc.ac.uk!mg
>From: [email-masked] (M.Golding)
>Newsgroups: comp.lang.c++
>Subject: MS Visual C++ 1.5, list boxes
>Date: Tue, 14 Feb 95 09:50:30 GMT
>Organization: University of Kent at Canterbury, UK.
>Lines: 15
>Sender: [email-masked]
>Distribution: world
>Message-ID: <[email-masked]>
>NNTP-Posting-Host: eagle.ukc.ac.uk
>
>
>howdy,
>
>Is there an easy way of allowing a list box (CListBox) in visual c++ to 
>have different coloured items within the list ???
>
>for example, a liabrary system that has a list of books that are out, the
items
>in red being overdrawn the ones in blue are not YET.
>
>cheers 
>Martin
>
>
>
>

K. Muthu Kumar,
British Telecom Plc, PP.304, Lion House, 72-5 Red Lion Street,
Holborn, LONDON - WC1R 4RT, UNITED KINGDOM
CIX: [email-masked]   CIS: 100411,743