May 11, 2024, 01:49:15 PM

News:

Own IWBasic 2.x ? -----> Get your free upgrade to 3.x now.........


Listview and clicks

Started by Bruce Peaslee, July 15, 2009, 03:18:50 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Bruce Peaslee

I have a list view with edit boxes and controls. Depending on which item is selected, the edit boxes contain different text and verious controls are either enabled or disabled. The routine that does this is called in response to LVN_ITEMCHANGED.

If the user clicks an item or uses the arrow keys, the hilighting works perfectly as the other controls are adjusted; but when one clicks in the control, but not on an item, the hilighting disappears. Then list view is created with @LVSSHOWSELALWAYS, but to no effect.

Any suggestions?

Thanks.
Bruce Peaslee
"Born too loose."
iTired (There's a nap for that.)
Well, I headed for Las Vegas
Only made it out to Needles

sapero

Bruce, this is the default behavior, compare with regedit or any other application with listview. You can change it by responding to NM_CUSTOMDRAW notification, drawing the selection if the item has at least keyboard focus (CDIS_SHOWKEYBOARDCUES, LVIS_FOCUSED).

Bruce Peaslee

Thanks. I'll give it a try.
Bruce Peaslee
"Born too loose."
iTired (There's a nap for that.)
Well, I headed for Las Vegas
Only made it out to Needles