Home > Software engineering >  MFC listbox hide after the show can't response message
MFC listbox hide after the show can't response message

Time:10-15

I create a hidden listbox, when an edit box shows the listbox when get the input focus, found the listbox cannot response message,

CodePudding user response:

How does not respond??

CodePudding user response:

Is such as one of the items you choose, not into my selchange message processing function

CodePudding user response:

This message is sent by an application when the selection in a list box is about to change. The parent window of the list box receives This message through the WM_COMMAND message.
Your ListBox control's parent window is which?

CodePudding user response:

This message is not sent if the LB_SETCURSEL message changes the selection.

This message applies only to a list box that has the LBS_NOTIFY style.

For a multiple - selection list box, the LBN_SELCHANGE message is sent whenever the user presses the an arrow key, even if the selection does not change.

CodePudding user response:

Is ah, in the main window window created by the MFC based on the project window,

CodePudding user response:

In fact, I found that if the show from the start, can response message, but once the first hidden using showwindow function after the listbox, reoccupy showwindow function display listbox cannot respond to the news,,,

CodePudding user response:

The EnableWindow (TRUE);
  • Related