在Form的KeyDown事件里:
if Key = VK_UP then
begin
keybd_event(VK_SHIFT,0,0,0);
keybd_event(VK_TAB,0,0,0);
keybd_event(VK_TAB,0,KEYEVENTF_KEYUP,0);
keybd_event(VK_SHIFT,0,KEYEVENTF_KEYUP,0);
end;
if Key=Vk_down
begin
//keybd_event(VK_SHIFT,0,0,0);
keybd_event(VK_TAB,0,0,0);
keybd_event(VK_TAB,0,KEYEVENTF_KEYUP,0);
//keybd_event(VK_SHIFT,0,KEYEVENTF_KEYUP,0);
end;
对不住,系统快崩溃了,要重启~