Board index » delphi » How can intercept or receiving keyboard messages ?

How can intercept or receiving keyboard messages ?

I want to make a program that receiving keyboard
messages (preferable with WM_CHAR) of all the system,
that is to say, of all the applications that they in
their moment become active.
How could make it ?

Please reply to : LBa...@LatinMail.com

thanxs

 

Re:How can intercept or receiving keyboard messages ?


Quote
Luis Banda wrote:

> I want to make a program that receiving keyboard
> messages (preferable with WM_CHAR) of all the system,
> that is to say, of all the applications that they in
> their moment become active.
> How could make it ?

You need to install a hook to the keyboard (e.g. WH_KEYBOARD hook).

Look up: SetWindowsHookEx, UnhookWindowsHookEx(Hook).

Or search the web, or these newsgroups, for Hook examples.

--
Charles Hacker
Lecturer in Electronics and Computing
School of Engineering
Griffith University - Gold Coast
Australia

Other Threads