CB_GETEDITSEL

2.x

CB_GETEDITSEL
wParam = 0;     /* not used, must be zero */
lParam = 0L;    /* not used, must be zero */

An application sends a CB_GETEDITSEL message to retrieve the starting and ending character positions of the current selection in the edit control of a combo box.

Parameters

This message has no parameters.

Return Value

The return value is a doubleword value that contains the starting position in the low-order word and the position of the first nonselected character after the end of the selection in the high-order word.

Example

This example retrieves the selection positions of the edit control of a combo box, and converts them into starting and ending positions:

DWORD dwResult;
WORD wStart, wEnd;

dwResult = SendDlgItemMessage(hdlg, ID_MYCOMBOBOX,
        CB_GETEDITSEL, 0, 0L);
wStart = LOWORD(dwResult);
wEnd   = HIWORD(dwResult);

See Also

CB_SETEDITSEL