Howto quit a console application ??

J

J?rg Brenner

Hello!
Does anyone know how to quit a console application? There ist no
static 'Application'-Object (with the method 'Quit()') like in
Windows-Applications.

Thanks for any hints,

Jörg from Munich
 
J

Jon Skeet [C# MVP]

J?rg Brenner said:
Does anyone know how to quit a console application? There ist no
static 'Application'-Object (with the method 'Quit()') like in
Windows-Applications.

There's Environment.Exit() or you could just make sure that all your
foreground threads have finished running.
 
S

Sijin Joseph

Have you tried returning from Main() .. i think that should end your
application.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top