how to check if user is using a mouse ??

  • Thread starter Thread starter Piotrek
  • Start date Start date
P

Piotrek

hi,
I need to check if someone is really using workstation or not.
As using i mean moving mouse, or clicking keyboard. There
are a lot of "ergonomical helper" application (workrave for example)
that will stop users work after several minutes of real work, that
apps even know if you are realy having a brake (same mouse movement
monitoring). How can i do something like this using C# (is it windows forms
related question) ??? (my app is minimized to tray (notifiicon near clock))

tia
piotrek
 
There's a good article here about it:

Thanks for help, the code published there looks very bad in firefox :(
but i encoded it well and that hook setings work. But it works
only when i have my app maximized and mouse pointer is over it.
Does anyone know what to do if i want to minimize my app to
notifyicon only and still get mouse coordinates.

Is it possible to create a timer that will query system about mouse
coordinates
from time to time (im writing app that need to know if user works (i mean
user moves mouse by working)).
 
i already got my answer myself :) I can get cursor position from
Cursor.Position
in some timer event or in separate thread to watch mouse movements.
 
Back
Top