![]() |
TAB-Ereignis in Controls auf andere Taste verlagern
Ich habe ein TEDIT bzw. TDBEDIT-Control, welches auf die Eingabe von <ENTER> exakt in der gleichen Weise reagieren soll, als wenn <TAB> betätigt wird. Wie lässt sich so etwas bewerkstelligen?
|
Re: TAB-Ereignis in Controls auf andere Taste verlagern
Delphi-Quellcode:
procedure TForm.FormKeyPress(Sender: TObject; var Key: Char);
begin If Key =#13 then Self.Perform(WM_NEXTDLGCTL,0,0); end; |
Re: TAB-Ereignis in Controls auf andere Taste verlagern
noch besser:
Delphi-Quellcode:
procedure TForm.FormKeyPress(Sender: TObject; var Key: Char);
begin If (Key = #13) then begin Key := #0; Self.Perform(WM_NEXTDLGCTL,0,0); end; end; |
Alle Zeitangaben in WEZ +1. Es ist jetzt 10:25 Uhr. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz