System.UnauthorizedAccessException Class
Represents the error that occurs when an I/O operation cannot be performed because of incompatible file access levels.

See Also: UnauthorizedAccessException Members

Syntax

[System.Runtime.InteropServices.ComVisible(true)]
public class UnauthorizedAccessException : SystemException

Remarks

UnauthorizedAccessException is typically thrown when a request is made to write to a read-only file, or a file I/O operation is requested on a directory.

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