System.Environment Class

Provides information about, and means to manipulate, the current environment and platform. This class cannot be inherited.

See Also: Environment Members

Syntax

[System.Runtime.InteropServices.ComVisible(true)]
public static class Environment

Remarks

Use the Environment class to retrieve information such as command-line arguments, the exit code, environment variable settings, contents of the call stack, time since last system boot, and the version of the common language runtime.

Thread Safety

All public static members of this type are safe for multithreaded operations. No instance members are guaranteed to be thread safe.

Requirements

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