I’d like to pause my program if a user is inactive for 5 minutes. By inactive I mean hasn’t pressed their mouse or their keyboard during that time (including outside the program too!). Any starting points?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Within a timer you could p/invoke
GetLastInputInfo()which will return the number ms since input was detected from the user, across all processes in the current session.