This control looks really great. Just a question from a newbie, how do you put the checkboxes in the listbox?
Many thanks
Listbox with checkboxes
Re: Listbox with checkboxes
Hi,
The native listbox control of Windows does not support checkboxes. For such a requirement a listview is the better choice. Take a listview, set it to Details view, make it hide the header, insert a column and then the items. You can make the column width equal the control width minus the control's border or you can make it autosize to the widest item.
The alternative is to make the listbox ownerdrawn and draw the checkboxes yourself. The Fonts and Colors sample demonstrates how to owner-draw a listbox.
Regards
TiKu
The native listbox control of Windows does not support checkboxes. For such a requirement a listview is the better choice. Take a listview, set it to Details view, make it hide the header, insert a column and then the items. You can make the column width equal the control width minus the control's border or you can make it autosize to the widest item.
The alternative is to make the listbox ownerdrawn and draw the checkboxes yourself. The Fonts and Colors sample demonstrates how to owner-draw a listbox.
Regards
TiKu
Crunching for Fab36_Folding-Division at Folding@Home. Join Fab36/Fab30! - Folding@Home and BOINC
Boycott DRM! Boycott HDCP!
Boycott DRM! Boycott HDCP!