fileinfo FileAttributes property
Return to Introduction  Previous page  Next page
Applies to
dcFileInfo component.  

  TdcFileInfoAttributes = set of (fiaArchive, fiaHidden, fiaReadOnly, fiaSystem, fiaDirectory, fiaTemporary, fiaCompressed, fiaOffline);  
property FileAttributes: TdcFileInfoAttributes;  

The FileAttributes property determines and changes the attributes for the file specified in the FileName property.  
fiaArchiveThe file is an archive file. Applications use this value to mark files for backup or removal;  
fiaHiddenThe file is hidden. It is not included in an ordinary directory listing;  
fiaReadOnlyThe file is read-only. Applications can read the file but cannot write to it or delete it;  
fiaSystemThe file is part of the operating system or is used exclusively by it;  
fiaDirectoryThe file is a directory;  
fiaTemporaryThe file is being used for temporary storage. Applications should write to the file only if absolutely necessary. Most of the file's data remains in memory without being flushed to the media because the file will soon be deleted;  
fiaCompressedThe file or directory is compressed. For a file, this means that all of the data in the file is compressed. For a directory, this means that compression is the default for newly created files and subdirectories;  
fiaOfflineThe data of the file is not immediately available. Indicates that the file data has been physically moved to offline storage.  

1.fiaTemporary, fiaCompressed and fiaOffline attributes works on NT-family machines only.  
2.If you'd like to change file attributes make sure that file not locked by another application. Otherwise they will remains untouched.  
3.You can NOT set fiaDirectory flag to usual file, or clear this flag from the directory. You can not change fiaDirectory attribute at all.  
See also
DisplayName, FileSize, FileType, TimeCreated, TimeLastModified properties.