I have a listview in report style with checkboxes.
Is there any easy way to make the check box appear disabled? To give it a tristate sort of effect?
I want to have 3 states: Enabled, Disabled, and Unset.
I have a listview in report style with checkboxes. Is there any easy way
Share
The standard
LVS_CHECKBOXESstyle does not support tri-state checkboxes. However,LVS_CHECKBOXESis internally implemented as a ListView-managed ImageList and normal ListView state indexes, so you can simply assign your own ImageList to the ListView, put three checkbox images into it, and set each ListView item’s state index as needed. Then you just need to handle mouse messages for the ListView to switch between state indexes when clicking on an item’s state image.