다음을 통해 공유


EM_POSFROMCHAR (Windows CE 5.0)

Send Feedback

This message retrieves the coordinates of the specified character in an edit control.

EM_POSFROMCHAR wCharIndex = (WPARAM) wParam;

Parameters

  • wCharIndex
    Specifies the zero-based index of the character.

Return Values

The return value is the position of the character (x, y). For a single-line edit control, the y-coordinate is always zero.

Remarks

On return, the x-coordinate of the character is contained in the LOWORD of the LRESULT and the y-coordinate is contained in the HIWORD of the LRESULT.

Any index beyond the last character returns –1.

A returned coordinate can be negative if the character has been scrolled outside the client area of the edit control. The coordinates are truncated to integer values.

If wCharIndex is the index of a line delimiter, the returned coordinates are of the position just past the last visible character in the line.

If wCharIndex is greater than the index of the last character in the control, the returned coordinates are of the position just past the last character of the control.

Requirements

OS Versions: Windows CE 1.0 and later.
Header: Windows.h.

See Also

EM_CHARFROMPOS | Edit Boxes Messages

Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.