The LBSELCHSTRING message is sent to an application's hook function by the Open or Save As dialog box whenever the user makes or changes a selection in the File Name list box. This message lets an application identify a new selection and carry out any application-specific actions, such as updating a custom control in the dialog box.
wParam
Identifies the list box in which the selection occurred.
lParam
Identifies the list box item and type of selection. The low-order word of the lParam parameter identifies the list box item. The high-order word of the lParam parameter is one of the following values:
Value | Meaning |
CD_LBSELCHANGE | Specifies that the item identified by the low-order word of lParam was the item in a single-selection list box. |
CD_LBSELSUB | Specifies that the item identified by the low-order word of lParam is no longer selected in a multiple-selection list box. |
CD_LBSELADD | Specifies that the item identified by the low-order word of lParam was selected from a multiple-selection list box. |
CD_LBSELNOITEMS | Specifies that no items exist in a multiple-selection list box. |
The application returns zero.
To use the LBSELCHSTRING message, the application must create a message identifier by using the RegisterWindowMessage function and passing the LBSELCHSTRING constant as the function's single parameter.