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 Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Shutting down your application 1

Status
Not open for further replies.

djam

Technical User
Nov 15, 2002
223
CA
How would I shut down my application from anywhere in my code?

thanks

" ahhh computers, how they made our lives much simpler ;) "
 
You can call Application.Exit, which is a fairly gentle shutdown, or call Environment.Exit, which is equivalent to killing the process (very abrupt end).

Neither are what I would prefer to do, as in the past there have always been some resources that didn't get cleaned up. In the .NET world, they'll probably get freed ... eventually.

I would try and find a way to gracefully unwind your call stack, cleaning up as you go.

Chip H.


____________________________________________________________________
If you want to get the best response to a question, please read FAQ222-2244 first
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top