docs

Home All functions Categories

vuDiskSpace(Drive)

vuDiskSpace(*CSTRING), CSTRING

Description

Returns the actual size of the specified disk in bytes. Unlike older APIs, this function is not limited to 2 GB.

Since Clarion has difficulty with very large integers, the value is returned as a formatted string (e.g., 123,456,789). Use the Clarion DEFORMAT command to extract numeric values if needed.

Parameters

Parameter Data Type Description
Drive CSTRING(2) Drive letter (e.g., 'C')

Returns

A null-terminated CSTRING containing the size of the drive in bytes (formatted with commas).

Example

LOC:Size  REAL
LOC:Drive = 'C'

LOC:Size = DEFORMAT(vuDiskSpace(LOC:Drive))
MESSAGE('C Drive is ' & vuDiskSpace(LOC:Drive) & ' bytes')

Notes

Home All functions Categories