Computing.Net > Forums > Programming > stop log off operation using VB

Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.

stop log off operation using VB

Reply to Message Icon

Name: badbloodyeyez
Date: December 24, 2008 at 04:08:48 Pacific
OS: Windows XP Pro
CPU/Ram: 1GB
Product: Novatech / DONT KNOW
Comment:

Hi, I am currently learning VB and I want to know is it possible to stop the window being log off, restart and shutdown using VB?? I want to automatically detect if the window is restarting, log off or shutdown if so then it will stop it and send a character (it can be any thing) to USB port and resume the operation of log off, restart or shutdown. I want to know if it is possible in VB or in other programmin I have used Batch file but its not very useful as it doesnt stop the operation automatically. If you have any suggestions or can help me with the code I will really appriciate it thanks



Sponsored Link
Ads by Google

Response Number 1
Name: tonysathre
Date: December 24, 2008 at 04:51:24 Pacific
Reply:

Google

Maybe this:


Private Sub Form_QueryUnload(Cancel As Integer, UnloadMode As Integer)
If UnloadMode = vbAppWindows Then
'Windows is shutting down
'do your code here
End If
End Sub


0
Reply to Message Icon

Related Posts

See More







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


Sponsored links

Ads by Google


Results for: stop log off operation using VB

Mute Modem using VB www.computing.net/answers/programming/mute-modem-using-vb/8154.html

logging off www.computing.net/answers/programming/logging-off/5712.html

Comparing Files+Folders using VBS www.computing.net/answers/programming/comparing-filesfolders-using-vbs/14112.html