I'm running some login forms that need to restart in case a user walks away from a terminal. Any ideas about detecting inactivity when the application is minimized or hidden?<br>
<br>
I'm flummoxed.<br>
<br>
D
Hmmmm.... you could write a screen saver that sends "restart messages" (You define) to your program. It's easily disabled though...<br>
Or you could start a timer within your program that is reset everytime there is mouse/keyboard activity. Use<br>
SetTimer(hwnd, 1, 1000, NULL); <br>
This will send WM_TIMER messages to your program every second. Next, increment a varable for the desired # of seconds & reset the variable only when the window has input focus / user input.<br>
Don't forget to KillTimer(hwnd, 1); before exiting your program.<br>
<p> <br><a href=mailto:Kim_Christensen@telus.net>Kim_Christensen@telus.net</a><br><a href=
Thanks for the suggestion. I decided to use a small screensaver app to run my app, or even run the whole thing as a screensaver. Not secure but security isn't important for this thingy.<br>
<br>
thanks again<br>
D
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.