NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

File.Attributes

Gets or sets the attributes of the current file.

[Visual Basic]
Overridable Public Property Attributes As FileSystemAttributes
[C#]
public FileSystemAttributes Attributes {override get; override
   set;}
[C++]
public: __property virtual FileSystemAttributes get_Attributes();
public: __property virtual void set_Attributes(FileSystemAttributes);
[JScript]
public function get Attributes() : FileSystemAttributes;
public function set Attributes(FileSystemAttributes);

Property Value

Current file attributes.

Exceptions

Exception Type Condition
FileNotFoundException The caller attempts to access a file that does not exist on disk.
SecurityException The caller does not have the required permission.
ArgumentException The caller attempts to set an invalid file attribute.
IOException Refresh cannot initialize the data.

Remarks

The value of this property is a combination of the archive, compressed, directory, hidden, offline, read-only, system, and temporary file-attribute flags.

Requirements

NGWS Runtime Security:

FileIOPermissionAccess Write permission required to set the attributes for the specified file.

See Also

File Class | File Members | System.IO Namespace