Hi Jos,
That doesn't really seem like a valid assumption to me. If the application is for serious data entry, it should work well without the user ever touching the mouse. The user may have just saved a record by hitting a keystroke (the save key), and that may be the same state the system was in (using those 3 criteria) an hour ago.
>Hi Kevin
>
>A custom timer object could have three additional properties to hold (1) the last key pressed, (2) the last mouse x position, and (3) the last mouse y position. In the timer init event set the three properties using LASTKEY(), MROW(), and MCOL(). Set the timer interval to 60 minutes (or whatever period is required).
>
>When the timer event fires compare the three properties to their current states. If any of them are different update the properties with the new (current) values and return normally. If the current state is identical then I would assume the system is idle i.e. no keyboard activity and no mouse movement for the timer interval, then quit the application.
>
>Running a timer consumes very little processing power or other resources.
>
Steve Gibson