Mono Class Library: Mono.Unix.UnixDirectoryInfo Overview | Members

Mono.Unix.UnixDirectoryInfo.GetCurrentDirectory Method

Returns the application's current working directory.

public static string GetCurrentDirectory ()

See Also

Mono.Unix.Native.Syscall.getcwd

Returns

A string containing the path of the current working directory.

Exceptions

TypeReason
UnauthorizedAccessException Permission to read or search a component of the current working directory was denied. [Mono.Unix.Native.Errno.EACCESS]
System.IO.FileNotFoundException The current working directory has been unlinked. [Mono.Unix.Native.Errno.ENOENT]

Remarks

Requirements

Namespace: Mono.Unix
Assembly: Mono.Posix (in Mono.Posix.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0