Hello:

  I created a listview, and set the LVS_EX_CHECKBOXES style.

  But, How to get&set the check state of each item ?

  I don't know which message I should send.

  Thank you.
Posted on 2005-11-09 19:35:12 by seasea
this is stated clearly by PlatformSDK:

LVS_EX_CHECKBOXES
Version 4.70. Enables check boxes for items in a list-view control. When set to this style, the control creates and sets a state image list with two images using DrawFrameControl. State image 1 is the unchecked box, and state image 2 is the checked box. Setting the state image to zero removes the check box altogether.

Version 6.00 Check boxes are visible and functional with all list-view modes except the tile view mode introduced in ComCtl32.dll version 6. Clicking a checkbox in tile view mode only selects the item; the state does not change.
Note  Comctl32.dll version 6 is not redistributable but it is included in Microsoft Windows XP or later. To use Comctl32.dll version 6, specify it in a manifest. For more information on manifests, see Using Windows XP Visual Styles.

You can obtain the state of the check box for a given item with ListView_GetCheckState. To set the check state, use ListView_SetCheckState. If this style is set, the list-view control automatically toggles the check state when the user clicks the check box or presses the space bar.
Posted on 2005-11-09 19:42:44 by ti_mo_n
ti_mo_n :

  I will read the msdn carefully.

  Thank you.
Posted on 2005-11-10 18:27:14 by seasea