Published By | Date | Version | Knowledge Level | Keywords |
---|---|---|---|---|
Revelation Technologies | 14 NOV 1989 | 2.X | EXPERT | DSPACE page, , |
DSPACE computes the amount of space remaining for a specified disk.
DSPACE(disk, space, clusters, clust.size, sect.size, disk.size)
Use DSPACE to return the number of bytes (and other operating system data) remaining on a specified drive.
Use disk to pass the drive where the disk is to be found. A colon is not required (i.e., either C or C: is fine).
DSPACE will return in space the number of bytes available.
DSPACE returns in clusters the number of clusters available.
DSPACE returns in clust.size the number of sectors per cluster.
DSPACE returns in sect.size the number of bytes per sector.
DSPACE returns in disk.size the number of clusters per disk.
The remaining disk space, number of clusters, size of clusters, size of sector, and number of clusters per disk are returned in the respective argument list parameters.
/* The following code reports available space on drive C:, as well as other statistics. */ DECLARE SUBROUTINE DSPACE, MSG disk = "C" DSPACE(disk, space, clusters, clust.size, sect.size, disk.size) text = "Space available: ":space text<<-1>> = "Number of clusters: ":clusters text<<-1>> = "Cluster size is: ":clust.size text<<-1>> = "Sector size is: ":sect.size text<<-1>> = "Disk size is: ":disk.size MSG(text, "", "", "")