Posted By

christianjunk on 02/04/11


Versions (?)

Who likes this?

1 person have marked this snippet as a favorite


How to get command line arguments for windows application in c#

 / Published in: C#

It can use this in any place of its application, not only main () like in an application of console is limited its use in the method.

  1. string[] args = Environment.GetCommandLineArgs();
  3. foreach(string arg in args){
  4. // Your Things
  5. }

Report this snippet  

You need to login to post a comment.