Share via


File.SetAttributes Method

Sets the specified FileAttributes of the file on the specified path.

Namespace: System.IO
Assembly: mscorlib (in mscorlib.dll)

Syntax

public static void SetAttributes (
         stringpath,
         FileAttributesfileAttributes
)

Parameters

  • path
    The path to the file.
  • fileAttributes
    The desired FileAttributes, such as Hidden, ReadOnly, Normal, and Archive.

Version Information

Available in the .NET Micro Framework versions 3.0, 4.0, and 4.1.

See Also

Reference

File Class
File Members
System.IO Namespace