April 23rd, 2012, 09:51 AM
CListCtrl: After scroll event received, the checkbox can not be clicked
i had a CListCtrl with Checkboxes in the first column. If i start my application i can click my checkbox or change his state. The Problem i had is, that if i scroll down to the end of the list, i can not click on any checkbox or change the state. If i click on the item name, i geht the NM_CLICK event, but on if i click on the checkbox, no event can be received.
Does anybody had an idea, why my CListCtrl doesn't work?
ON_NOTIFY(NM_CLICK, LV_TS_CTE_TESTCASES, OnLVClick)
ON_NOTIFY(LVN_ITEMCHANGED, LV_TS_CTE_TESTCASES, OnLVChanged)
ON_NOTIFY(NM_CUSTOMDRAW, LV_TS_CTE_TESTCASES, OnCustomdrawList)
Have I forgotten something???
April 23rd, 2012, 02:35 PM
Re: CListCtrl: After scroll event received, the checkbox can not be clicked
First of all, NM_CLICK is not an event, it is a notification code received as one of the parameters of the WM_NOTIFY message.
In order to determine is going on, you would have to show code snippets from your WM_NOTIFY message handlers.
I think, most likely is NM_CUSTOMDRAW notification handler (preventing redraw?).
I am also not sure why you have to handle all three (NM_CLICK, LVN_ITEMCHANGED and NM_CUSTOMDRAW) notifications?
There are only 10 types of people in the world:
Those who understand binary and those who do not.
Click Here to Expand Forum to Full Width