[Lazarus] *** GMX Spamverdacht *** Re: TEdit: Find character at caret position

Jürgen Hestermann juergen.hestermann at gmx.de
Mon Aug 3 09:30:13 CEST 2015


Am 2015-08-02 um 20:32 schrieb Howard Page-Clark:
 > On 02/08/2015 18:33, Jürgen Hestermann wrote:
 >> In a TEdit component, how do I find out which character is at the
 >> caret/cursor position?
 >> Or in other words: At which (string) position will the next typed
 >> character be inserted?
 >> I want to insert text at just that position myself but cannot find out
 >> where this (character) position would be.

 > Edit1.SelStart gives the character position of the caret/cursor. The next typed character is inserted at Succ(Edit1.SelStart).

Sure? I thought SelStart gives the start of the selected text, not of the cursor.





More information about the Lazarus mailing list