I’m using the following code to remove the check box next to a specific item in my List View:
LVITEM lvI;
lvI.iItem = i;
lvI.mask = LVIF_STATE;
lvI.stateMask = LVIS_STATEIMAGEMASK;
lvI.state = 0;
SendMessage(hListOutput, LVM_SETITEM, 0, (LPARAM) &lvI);
It works, but if I click where the check box used to be it re-appears!
How can I remove the check box on a specific item in my list view, and keep it removed?
Save the desired state of the check box in a variable (default null). In the check box changed event, if that variable is not null flip the state to the saved value.