//注册全局热键
RegisterHotKey(Handle,1,0,VK_F2);
RegisterHotKey(Handle,2,0,VK_F3);
RegisterHotKey(Handle,3,0,VK_F4);
procedure WMHotKey(var AMsg: TWMHotkey); message WM_HOTKEY;
procedure TfrmMain.WMHotKey(var AMsg: TWMHotkey);
begin
case AMsg.HotKey of
1: ; //F2
2: ; //F3
3: ; //F4
end;
end;