Computing.Net > Forums > Programming > No user activity Control in VB.NE

Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Click here to start participating now! Also, check out the New User Guide.

No user activity Control in VB.NE

Reply to Message Icon

Name: cess
Date: June 9, 2006 at 12:26:27 Pacific
OS: XP
CPU/Ram: amd sempron 3000+
Product: AMD
Comment:

I wrote a windows service service in VB.NET and i want it
to run when there is no user activity (like screensavers) and to stop when the user is active.

Please help me !!
Please





Response Number 1
Name: SN
Date: June 10, 2006 at 17:20:19 Pacific
+1
Reply:

There's no native .NET event to do this, but you can fake it by having a timer that checks the system for how long since the last keyboard or mouse input. To do that, you would import the getlastinputinfo function from user32.dll. Check out this VB.NET System idle program for the details.

Good luck,
-SN


Reply to Message Icon

Related Posts

See More


Help with Batch File newbie VB question



Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Programming Forum Home


Google Ads



Results for: No user activity Control in VB.NE

CRviewer control in VB 6 www.computing.net/answers/programming/crviewer-control-in-vb-6/580.html

Code save file dialog box in vb.net www.computing.net/answers/programming/code-save-file-dialog-box-in-vbnet/18050.html

gamma control in vb www.computing.net/answers/programming/gamma-control-in-vb/5186.html