X
xiaoxian
Unregistered / Unconfirmed
GUEST, unregistred user!
小小问题:回车键代替tab键,怎样让焦点在窗体中的控件移动??一下代码不好使阿,怎么回事???
procedure Tfrm.FormKeyDown(Sender: TObject; var Key: Word;
Shift: TShiftState);
begin
if Key=VK_Return then
begin
SelectNext(ActiveControl,True,True);
Key:=VK_tab;
end;
end;
procedure Tfrm.FormKeyDown(Sender: TObject; var Key: Word;
Shift: TShiftState);
begin
if Key=VK_Return then
begin
SelectNext(ActiveControl,True,True);
Key:=VK_tab;
end;
end;