unit Unit1;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls, Buttons;
type
TForm1 = class(TForm)
SpeedButton1: TSpeedButton;
Edit1: TEdit;
Edit2: TEdit;
procedure FormCreate(Sender: TObject);
private
procedure DoEnterAsTab(Var Msg: TMsg; Var Handled: Boolean);
{ Private declarations }
public
{ Public declarations }
end;
var
Form1: TForm1;
implementation
{$R *.dfm}
procedure TForm1.DoEnterAsTab(Var Msg: TMsg; Var Handled: Boolean);
Begin
If Msg.Message = WM_KeyDown Then
If Msg.wParam = 34 Then
Keybd_event(VK_TAB,0, 0, 0);
End;
procedure TForm1.FormCreate(Sender: TObject);
begin
Application.OnMessage := DoEnterAsTab;
end;
end.