开发者

It is posible to create a hotkey in a Delphi console application?

I tried:

RegisterHo开发者_如何学编程tKey(GetConsoleWindow(),$29A,MOD_ALT,'a') 

but it didn't work.

Do you have any idea?


You need a message loop to receive WMHotKey messages. Do you have a message loop in your console application?

Edit:

Try capital 'A' instead of 'a'. Because the last parameter of RegisterHotkey wants a Virtual-key code. And the virtual-key code of letter A is 0x41 = 'A'.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜