Returns information about a drive.
// Total disk size?
ResDiskSize is numeric = fDriveInfo("C:", fdTotalSpace)
Syntax
<Result> = fDriveInfo(<Disk path> , <Information>)
<Result>: All types
- Requested information.
- 0 if an error occurs. To get more details on the error, use ErrorInfo with the errMessage constant.
<Disk path>: Character string
Path of disk to use in the following format:- <drive letter>:. For example: "A:". The drive letter is written in uppercase character.
- UNC path. For example: "\\<ServerName>\<ShareName>".
<Information>: Constant
Specifies the requested type of information: | |
fdDriveType | Type of drive (see the table below) |
fdFileNameSize | Maximum size of file name on the disk (in characters) |
fdFreeSpace | Available disk space (in bytes) |
fdNbCluster | Number of disk clusters |
fdNbSectorPerCluster | Number of sectors per cluster |
fdSectorSize | Size of sector (in bytes) |
fdSerialNumber | Serial number of the disk, defined when the disk is formatted (not the serial number given by the manufacturer). |
fdTotalSpace | Total size of the disk (in bytes) |
fdVolumeName | Name of volume |