Strange, because it ON SHUTDOWN should fire.
What you can't stop is someone terminating the application through task manager.
I wonder if people are getting the message "an application is stopping Windows from shutting down, shutdown anyway" (this isn't the actual message, but it's similar). In this case, Windows terminates the application and anything you do with ON SHUTDOWN or BINDEVENT won't work.
>I use the ON SHUTDOWN event to do housekeeping if the application is closed. However, it appears that the event is not triggered if the application is closed due to the user logging off from, or shutting down, Windows. Therefore, I plan to work with BINDEVENT.
>
>---Michael
Craig Berntson
MCSD, Microsoft .Net MVP, Grape City Community Influencer