Solved

Keystroke Count and Idle Time

Posted on 1998-03-20
1
321 Views
Last Modified: 2013-12-03
I support an app that is used by data-entry clerks running on win95, I'd like to capture their keystroke count and idle time for reporting.  Any nifty pieces of code or tips out there for capturing this type of info?

0
Comment
Question by:robsdman
1 Comment
 
LVL 11

Accepted Solution

by:
alexo earned 50 total points
ID: 1412185
See the SetWindowsHookEx() API.  You can capture keystrokes using a WH_KEYBOARD hook either globally or per-thread.  You can calculate the idle time by noting the time when each keystroke arrives.

See the SetWindowsHookEx() documentation.  Visual C++ also contains sample applications.

If you want to integrate the capturing into the application itself, you can preprocess the keyboard messages (WM_KEYDOWN, etc.) or WM_CHAR messages.
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

This article describes how to programmatically preset the "Pages per Sheet" option that's available with most printer drivers.   This setting lets you do "n-Up" printing, where two, four, or more pages are printed on each sheet of paper. If your …
With most software applications trying to cater to multiple user needs nowadays, the focus is to make them as configurable as possible. For e.g., when creating Silverlight applications which will connect to WCF services, the service end point usuall…
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…

830 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question