Quote Originally Posted by Atheist
Is this VB6 or VB.Net?
If it is VB.Net then you can simply add an eventhandler for the Microsoft.Win32.SystemEvents.SessionEnding event. In the eventhandler, set e.Cancel to true to cancel the logoff, do what you want, then programatically log out if needed.
It is VB6, though I have just downloaded 2008, but get all sorts of problem message about conversion.!