How to Quit Console Application
-
I have a console application spanning multiple methods and functions, and based on a flag value I wish to abort program execution. Is there any other method other than break(which cannot be used always)? Thanks! h.
-
I have a console application spanning multiple methods and functions, and based on a flag value I wish to abort program execution. Is there any other method other than break(which cannot be used always)? Thanks! h.
You basically want something like this, I can't help more without knowing more.
static bool abort; static void Main(string\[\] args) { while (!abort) { DoStuff(); } }
-
I have a console application spanning multiple methods and functions, and based on a flag value I wish to abort program execution. Is there any other method other than break(which cannot be used always)? Thanks! h.
-
I have a console application spanning multiple methods and functions, and based on a flag value I wish to abort program execution. Is there any other method other than break(which cannot be used always)? Thanks! h.
-
I have a console application spanning multiple methods and functions, and based on a flag value I wish to abort program execution. Is there any other method other than break(which cannot be used always)? Thanks! h.
Environment.Exit()
Vasudevan Deepak Kumar Personal Homepage Tech Gossips
-
Thanks. Environment.Exit() works. I was not aware this function.