Is Keyboard Hooks the answer to my problem
-
Hi there. I am currently working on a project to identify users using their typing dynamics. I want to use the intervals between keystrokes on the keyboard as a user type in their passwords, to identify the users. I am using Windows XP and Visual Studio C++ 2003 to develope a MFC application project. I want to use a dialog with an edit box to allow the user to enter his/her username and password. I cannot process the WM_KEYDOWN and WM_KEYUP messages because when you type in the edit box, the keyboard focus is on the edit box and not on the dialog. Will a keyboard hook help me in my mission or will I have to use something else. Something else that is easier to use will also work. If you could help me I would appreciate it alot. Thank You. Ben
-
Hi there. I am currently working on a project to identify users using their typing dynamics. I want to use the intervals between keystrokes on the keyboard as a user type in their passwords, to identify the users. I am using Windows XP and Visual Studio C++ 2003 to develope a MFC application project. I want to use a dialog with an edit box to allow the user to enter his/her username and password. I cannot process the WM_KEYDOWN and WM_KEYUP messages because when you type in the edit box, the keyboard focus is on the edit box and not on the dialog. Will a keyboard hook help me in my mission or will I have to use something else. Something else that is easier to use will also work. If you could help me I would appreciate it alot. Thank You. Ben
If you subclass the edit box, you can pick up the WM_KEYDOWN and WM_KEYUP messages (or indeed any other message), and process them. This article[^] shows how to capture key strokes to create a numeric-only edit box, but it shows how to capture the messages, process them, and then pass them on to the parent window, which is what you'll need to do, I would think.