SolFSStorage.GetFileAttributes method
Filter:
Pascal DLL C++ (DLL/Lib) C++ (VCL) C++ (.NET) C# VB.NETOverview
Returns object attributes.
Declaration
[Pascal]
function GetFileAttributes(const FileName: WideString) : LongWord;
[DLL]
long _stdcall StorageGetFileAttributes(unsigned long Storage, const wchar_t* FileName,
unsigned long & Attributes);
[C++ (DLL/Lib)]
unsigned long GetFileAttributes(unsigned short *fileName);
[C++ (VCL)]
void __fastcall GetFileAttributes(const WideString FileName, unsigned int &Attributes);
[C++ (.NET)]
long GetFileAttributes(String *fileName);
[C#]
int GetFileAttributes(String fileName);
[VB.NET]
Function GetFileAttributes(ByVal fileName As String) as Long
Parameters
- FileName - the full file name in the SolFSStorage.
- Attributes - returns file attributes mode.
- AttributesLevel - returns file attributes level. Level value of 0 means "default" value
- PagesPerCluster - returns the number of pages compressed as a single entity.
Return value
Object attributes (see values below).
[DLL] 0 if the function succeeded or one of Error codes if the function failed.
Values of Attributes
[Pascal] [DLL] [C++ (VCL)] [C++ (.NET)] [C#] [VB.NET] [ActiveX] [VB]
Value
Description
Can be set with SetFileAttributes
attrFile
1 (0x1)
Specifies that the entry is a file
no
attrDirectory
2 (0x2)
Specifies that the entry is a directory
no
attrCompressed
8 (0x8)
Specifies that the file is compressed
no
attrEncrypted
16 (0x10)
Specifies that the file is encrypted
no
attrSymLink
32 (0x20)
Specifies that the entry is a symbolic link
no
attrReadOnly
64 (0x40)
Specifies that the file is read-only. The attribute is not used by SolFS.
yes
attrArchive
128 (0x80)
Specifies that the file requires archiving. The attribute is not used by SolFS.
yes
attrHidden
256 (0x100)
Specifies that the file is hidden. The attribute is not used by SolFS.
yes
attrSystem
512 (0x200)
Specifies that the file is system. The attribute is not used by SolFS.
yes
attrTemporary
1024 (0x400)
Specifies that the file is temporary. The attribute is not used by SolFS.
yes
attrDeleteOnClose
2048 (0x800)
Specifies that the file should be deleted when the last handle to the file is closed. The attribute is currently not supported by SolFS.
yes
attrReserved0
0x1000
Reserved for future use
no
attrReserved1
0x2000
Reserved for future use
no
attrReserved2
0x4000
Reserved for future use
no
attrReserved3
0x8000
Reserved for future use
no
attrNoUserChange
attrFile | attrDirectory | attrDataTree | attrCompressed | attrEncrypted | attrSymLink | attrReserved0 | attrReserved1 | attrReserved2 | attrReserved3
Thse attributes can't be changed with SetFileAttributes
no
attrUserDefined
0xFFFF0000
A mask that specifies user-defined attributes
yes
attrAnyFile
0xFFFFFFFF
A mask that specifies entries with any attributes
Description
Use GeFileAttributes to determine object attributes.
