Re: Handle / detect <Alt> key combinations



Jamie,

keybd_event

keybd_event will let me simulate the key strokes. I want to be able to detect <Alt><Ctrl><anykey> presses. Can you point me to any code that shoes how to do that? This is how I am trying to do now:

procedure WMKeyDown(var Message : TWMKeyDown); message WM_KEYDOWN;

.....
.....

procedure TAppPanel.WMKeyDown(var Message : TWMKeyDown);
begin
inherited;

if (hwndApp <> 0) then
PostMessage(hwndApp, Message.Msg, Message.CharCode, Message.KeyData);

end;

But the above code doesn't get fired when <Alt> key is pressed. What should I do to trap <Ctrl><Alt><anykey> key presses?

.