int GetTextBoxLineIndexFromOffset (int panelHandle, int controlID, int byteOffset, int *lineNumber);
For the specified text box control, returns the zero-based index of the line
that contains the character at byteOffset bytes beyond the beginning of the text.
Input |
Name |
Type |
Description |
panelHandle |
integer |
Specifier for a particular panel that is currently in memory. You obtain this
handle from LoadPanel, NewPanel, or DuplicatePanel. |
controlID |
integer |
The defined constant, located in the .uir header file, that you assigned to the control in the User Interface Editor, or the ID returned by NewCtrl or DuplicateCtrl. |
byteOffset |
integer |
Number of bytes beyond the beginning of the text currently contained in the
text box, including any embedded newline characters. Must be greater than or
equal to zero. |
Output |
Name |
Type |
Description |
lineNumber |
integer |
Returns the zero-based index of the line containing the character that is
byteOffset bytes beyond the beginning of the text. If byteOffset exceeds the number of bytes in the text, the function returns the number of lines in the text box. |