Autor Beitrag
Karstadt
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 174

Windows 2000 / XP
Delphi 7 Pro
BeitragVerfasst: Do 08.12.05 10:27 
Hallo. Wie kann man das realisieren, denn das funktioniert bei mir nicht :)

ausblenden Delphi-Quelltext
1:
2:
3:
4:
procedure TForm1.DBGrid1KeyPress(Sender: TObject; var Key: Char);
begin
  If ord(key) = 13 Then Key := Chr(9);
end;
senidex
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 17

WIN XP

BeitragVerfasst: Do 08.12.05 18:37 
Hallo, vielleicht gibts etwas eleganteres, aber so gehts:


ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
procedure TForm1.DBGrid1KeyDown(Sender: TObject; var Key: Word;
  Shift: TShiftState);
begin
   if key = 13 Then    Key := 9;
   inherited;
end;

procedure TForm1.DBGrid1KeyPress(Sender: TObject; var Key: Char);
begin
    if ord(key) = 13 Then    Key := chr(9);
    inherited;
end;


Moderiert von user profile iconraziel: Delphi-Tags hinzugefügt.
alex517
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 60


D7Ent, FB, FIBPlus
BeitragVerfasst: Do 08.12.05 21:04 
Hi Karstadt,
schau doch mal hier nach
delphi.about.com/od/...using/a/entertab.htm
alex