Receive argument in Form

  • Thread starter Thread starter Elliot
  • Start date Start date
E

Elliot

Process.Start("WindowsFormsApplication1.exe","hi") to call app.exe to be
executed, then how to receive the argument "hi" in the Form?

Any idea would be appreciated.
 
Great. Thank you.


Peter Duniho said:
Environment.GetCommandLineArgs()

And alternatively, you can just make your Main() method the overload that
takes the arguments as parameters (as a string[] parameter) and inspect
them there.

Pete
 

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

Back
Top