Mono Class Library: System.Environment Overview | Members

System.Environment.GetCommandLineArgs Method

Returns the arguments specified on the command line.

public static string[] GetCommandLineArgs ()

Returns

Returns a string array. Each string in the array contains a single command line argument.

Remarks

The first element in the array contains the filename of the executing program. If the filename is not available, the first element is equal to string.Empty. The remaining elements contain any additional tokens entered on the command line.

Note:

The program filename can, but is not required to, include path information.

To obtain the command line as a single string, use the Environment.CommandLine property.

Requirements

Namespace: System
Assembly: mscorlib (in mscorlib.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0