<Return[S]><Top>

SHGetDiskFreeSpace

Declare Function Api_SHGetDiskFreeSpace& Lib "shell32" Alias "SHGetDiskFreeSpaceA" (ByVal pszVolume$, pqwFreeCaller As ULARGE_INTEGER, pqwTot As ULARGE_INTEGER, pqwFree As ULARGE_INTEGER)

Declare Function SHGetDiskFreeSpace Lib "shell32" Alias "SHGetDiskFreeSpaceA" (ByVal pszVolume As String, pqwFreeCaller As Currency, pqwTot As Currency, pqwFree As Currency) As Long

指定のディレクトリを含むディスクの空き容量を調べる。

パラメータ
pszVolume
    A null-terminated string that specifies the volume for which size information is retrieved.

    This can be a drive letter, Universal Naming Convention (UNC) name, or the path of a folder.

    You cannot use NULL to represent the current drive.
    When using Shell32.dll versions previous to version 5.0, this must be an ANSI string.

    Unicode is not supported in those versions.
pqwFreeCaller
    The address of a ULARGE_INTEGER value that receives the number of bytes on the volume available to the calling application.

    If the operating system implements per-user quotas, this value may be less than the total number of free bytes on the volume.
pqwTot
    The address of a ULARGE_INTEGER value that receives the total size of the volume, in bytes.
pqwFree
    The address of a ULARGE_INTEGER value that receives the number of bytes of free space on the volume.
 

戻り値
    関数が成功すると、TRUE を返す。それ以外は、FAISE を返す。