Click to See Complete Forum and Search --> : Intercept Global Messages / Events


kabilius
March 2nd, 2008, 04:25 PM
Hi all,

I have been trying to figure out how to intercept global messages, but I was not able to find relevent topics online.
I would like to intercept global messages / events such as keyboard strokes as well as mouse clicks.
Could someone give me some guidance on how to accomplish it.

I am using VS2005 c++ as my development tool.

Thank you for your help,
kab

Marc G
March 3rd, 2008, 11:19 AM
Use SetWindowsHookEx (http://msdn2.microsoft.com/en-us/library/ms644990.aspx)

kabilius
March 3rd, 2008, 11:44 AM
Use SetWindowsHookEx (http://msdn2.microsoft.com/en-us/library/ms644990.aspx)

Hi Marc G,

The third parameter in SetWindowsHookEx() is a handle to a DLL.
I have not yet built a DLL of my own before, so I am hoping to accomplish this without using any DLL; is it possible?

Thank you,
kab