Forum > General
how to TAB change ENTER error
(1/1)
Anonymous:
//ON KEYPRESS
if Key = #13 then begin
Key := #0;
if (Sender is TDBGrid) then
TDBGrid(Sender).Perform(WM_KeyDown,VK_Tab,0)
else
Perform(Wm_NextDlgCtl,0,0);
end;
WM_KeyDown not exists
Wm_NextDlgCtl not exists
VK_Tab not exists
this code funcions in a Delphi
jesusr:
no all code that works in delphi have to work or will work in fpc/lazarus, remember that delphi runs only under windows.
Try using OnKeyDown with something like:
if Key=VK_RETURN then begin
Key := 0;
PerformTab(true);
end;
(it's untested btw)
Navigation
[0] Message Index