PRB: WM_CHARTOITEM Messages Not Recieved by Parent of List Box

ID Number: Q72552

3.00

WINDOWS

Summary:

SYMPTOMS

When keyboard input is sent to a list box that has the

LBS_WANTKEYBOARDINPUT style bit set, its parent does not receive

WM_CHARTOITEM messages; however, WM_VKEYTOITEM messages are

received.

CAUSE

The list box has the LBS_HASSTRINGS style bit set.

RESOLUTION

Windows sets the LBS_HASSTRINGS style bit for all list boxes except

owner-draw list boxes. An owner-draw list box can be created with

this style bit turned on or off. For owner-draw list boxes, the

state of the LBS_HASSTRINGS style bit determines which messages are

sent. WM_CHARTOITEM messages and WM_VKEYTOITEM messages are

mutually exclusive.