Delphi-PRAXiS

Delphi-PRAXiS (https://www.delphipraxis.net/forum.php)
-   GUI-Design mit VCL / FireMonkey / Common Controls (https://www.delphipraxis.net/18-gui-design-mit-vcl-firemonkey-common-controls/)
-   -   Delphi OnKeyPress in einem Frame (https://www.delphipraxis.net/154683-onkeypress-einem-frame.html)

RWarnecke 21. Sep 2010 13:21

OnKeyPress in einem Frame
 
Hallo zusammen,

in meinem Programm nutze ich Frames um die unterschiedlichen Eingabeformulare darzustellen. Jetzt habe ich das Problem, dass ich mit der Enter-Taste nicht in das nächste Control springen kann. Da die Komponente TFrame kein OnKeyPress-Event besitzt.

Gibt es eine Möglichkeit, in einem Frame diese Event zu benutzen ?

Bummi 21. Sep 2010 15:41

AW: OnKeyPress in einem Frame
 
mhhhh... ich verwende immer Forms deren Parent ich setzte statt Frames...

Keypreview auf Deinem Form welches das Frame beinhatetet und
Delphi-Quellcode:
procedure TForm5.FormKeyPress(Sender: TObject; var Key: Char);
begin
if Key = #13 then
  begin
    Perform(WM_NEXTDLGCTL, 0, 0);
    Key := #0;
  end;
oder für alle Edits o.g. Prozedur zuweisen?


Alle Zeitangaben in WEZ +1. Es ist jetzt 10:51 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