EM_LINEFROMCHAR

This message is sent by an application to retrieve the index of the line that contains the specified character index in a multiline edit control. A character index is the number of characters from the beginning of the edit control.

At a Glance

Header file: Winuser.h
Windows CE versions: 1.0 and later

Syntax

EM_LINEFROMCHAR wParam = (WPARAM) ich; lParam = 0

Parameters

ich

Specifies the character index of the character contained in the line whose number is to be retrieved. If the ich parameter is –1, either the line number of the current line (the line containing the caret) is retrieved or, if there is a selection, the line number of the line containing the beginning of the selection is retrieved.

Return Values

The zero-based line number of the line containing the character index specified by ich indicates success.

Remarks

In a rich edit control, if the character index is greater than 64 KB, use the message EM_EXLINEFROMCHAR.

See Also

EM_LINEINDEX