Skip to main content
added 131 characters in body
Source Link
tinstaafl
  • 7k
  • 2
  • 17
  • 22

Is there a way to have the program run as a windows application normally but show a console if the help argument is passed?

For what you want, learn about using command line arguments here. Basically declare Main to accept arguments as an array of string:

static void Main(string[] args) 

Use a simple dialog form to display the help message or even a MessageBox which is a very simple dialog form..

This gives you much better control rather than trying to cobble something together that wasn't really meant to be put together.

For what you want, learn about using command line arguments here. Basically declare Main to accept arguments as an array of string:

static void Main(string[] args) 

Use a simple dialog form to display the help message or even a MessageBox which is a very simple dialog form..

This gives you much better control rather than trying to cobble something together that wasn't really meant to be put together.

Is there a way to have the program run as a windows application normally but show a console if the help argument is passed?

For what you want, learn about using command line arguments here. Basically declare Main to accept arguments as an array of string:

static void Main(string[] args) 

Use a simple dialog form to display the help message or even a MessageBox which is a very simple dialog form.

This gives you much better control rather than trying to cobble something together that wasn't really meant to be put together.

Source Link
tinstaafl
  • 7k
  • 2
  • 17
  • 22

For what you want, learn about using command line arguments here. Basically declare Main to accept arguments as an array of string:

static void Main(string[] args) 

Use a simple dialog form to display the help message or even a MessageBox which is a very simple dialog form..

This gives you much better control rather than trying to cobble something together that wasn't really meant to be put together.