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

Detect logoff or shutdown

P: n/a
How do you detect when a system is being logged off or shutdown? In VB 6
there was a QueryUnload event that would work if you had a form, but I'm
running in a Sub Main scenario... I can't find any events to code for... Is
there a way to register with the system to be notified of the
logoff/shutdown? Thanks.

Jerry
Nov 20 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
* "Jerry Camel" <rl*****@msn.com> scripsit:
How do you detect when a system is being logged off or shutdown? In VB 6
there was a QueryUnload event that would work if you had a form, but I'm
running in a Sub Main scenario... I can't find any events to code for... Is
there a way to register with the system to be notified of the
logoff/shutdown? Thanks.


<URL:http://dotnet.mvps.org/dotnet/samples/windowsandforms/downloads/CloseWindow.zip>

--
Herfried K. Wagner [MVP]
<URL:http://dotnet.mvps.org/>
Nov 20 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.