By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
434,654 Members | 1,840 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 434,654 IT Pros & Developers. It's quick & easy.

how to find the system idle time

chandru8
100+
P: 145
hi to all i need to find the system idle time and if the user doesnot use the system for more the a minute then i should lock the system

is it possible
can any one help in this.
thanks
Apr 10 '08 #1
Share this Question
Share on Google+
5 Replies


debasisdas
Expert 5K+
P: 8,127
1.run a timer
2.increment a counter variable in timer
3.handle the keystrokes and the mouse events.
4.every time any event occurs reset the counter.
5.once counter reaches a particular value call the system lock sub routine.
Apr 10 '08 #2

Expert 5K+
P: 8,434
hi to all i need to find the system idle time and if the user doesnot use the system for more the a minute then i should lock the system

is it possible
Sure - use a screensaver. This functionality is already built into Windows.
Apr 11 '08 #3

chandru8
100+
P: 145
is there any specific methods to handle mouse events
Apr 11 '08 #4

debasisdas
Expert 5K+
P: 8,127
is there any specific methods to handle mouse events
You need to handle all the mouse related events.
Apr 11 '08 #5

chandru8
100+
P: 145
Thanks For Your Reply Can You Give Any Example
Apr 11 '08 #6

Post your reply

Sign in to post your reply or Sign up for a free account.