(SST) ShlWAPIFunctionInfo Version 1.0

Developer Reference
TSSTAdvancedMemo.TextIndex Method
Retrieves the absolute index of the first character of the specified line number.
Scope
Public (i.e. this property can be referenced from any code, including that in other units, with access to the TSSTAdvancedMemo object of interest).
Syntax
FUNCTION TextIndex(alinenum : INTEGER) : INTEGER;  
Parameters
alinenum [in] A signed integer value that specifies the line number of which to determine the absolute index of the first character.
Return Values
If the function succeeds it returns the 0-based index of the first character (which doesn't necessarily have to be a printable character, e.g. a letter), of the line specified in the parameter passed to the function on call. If the function fails, it returns -1.
Remarks
Call this method to scroll a particular line into view, highlight text, and/or position the caret by means of methods/functions that require the absolute index, rather than the cartesian coordinates of a particular character.
The function uses the Windows edit control message EM_LINEINDEX to retrieve the return value.
Requirements
Unit (Declared and implemented in) SSTNewUnit.pas
Library SSTNewUnit.dcu/SSTNewUnit.obj
Unicode Implemented as ANSI version only.
See Also
TSSTAdvancedMemo, TSSTBasicTextSearchOptions, FindText.
 
Windows APIs: SendMessage, EM_LINEINDEX.


Document/Contents version 1.00
Page/URI last updated on April 28, 2022
 
Copyright © Stoelzel Software Technologie (SST) 2010 - 2017
Suggestions and comments mail to:
webmaster@stoelzelsoftwaretech.com