Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

VB.Net 2005

Status
Not open for further replies.

warnerpc

Technical User
Jun 14, 2004
19
US
Okay here is my problem. My program is running in the background monitoring activity. Now when ever a user logs off the machine "end task" comes up for my program. Is there away that I can get it so that it just automatically closes on its own?
 
Is it a service? If it isn't it should be if it is a background task.

Otherwise you'll have to catch the log off or shutdown event

you can do that from memory checking for queryendsession

note: that code bit stops the shutdown. you'll have to adapt but thats why we get paid the big bucks right??

[sub]____________ signature below ______________
The worst mistake you'll ever make is to do something simply the way you know how while ignoring the way it should be done[/sub]
 
Okay thank you for stating that it should be a service. The other gentleman that I'm working with does not agree with me that it should. I tried to explain to him that it would be easier to be a service. Thanks for pointing me in a direction
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top