![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() |
![]() ![]() ![]() | |
![]() | #WhiteUnicorn/ StartPage/ Documentation/DelphiFAQ > |
![]() ![]() |
How do I position the cursor (caret) in an edit or similar type control?
You can use the Delphi SelStart() and SelectLength() methods. Example: procedure TForm1.Button1Click(Sender: TObject); begin Edit1.SetFocus; {Move the caret to the second character} Edit1.SelStart := 2; {Do not select any text} Edit1.SelLength := 0; end;
![]() ![]() ![]() | |
![]() | #WhiteUnicorn/ StartPage/ Documentation/DelphiFAQ > |
![]() ![]() |
![]() ![]() | ||
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() |
![]() ![]() |
|
![]() ![]() |