AllAPI Network - The KPD-Team

 
Allapi Network
 API-Guide
 ApiViewer

 API List

 
API Resources
 Tips & Tricks
 VB Tutorials
 Error Lookup
 
Misc Stuff
 VB examples
 VB Tools
 VB Links
 Top Downloads
 
This Site
 Search Engine
 Contact Form
 

Donate to AllAPI.net

GetDiskFreeSpaceEx

The GetDiskFreeSpaceEx function obtains information about the amount of space available on a disk volume: the total amount of space, the total amount of free space, and the total amount of free space available to the user associated with the calling thread.

VB4-32,5,6
Declare Function GetDiskFreeSpaceEx Lib "kernel32" Alias "GetDiskFreeSpaceExA" (ByVal lpRootPathName As String, lpFreeBytesAvailableToCaller As Currency, lpTotalNumberOfBytes As Currency, lpTotalNumberOfFreeBytes As Currency) As Long

Operating Systems Supported
Windows NT 4.0 or later; Windows 95 OSR2 or later

Library
Kernel32

Parameter Information
· lpDirectoryName
Pointer to a null-terminated string that specifies a directory on the disk of interest. This string can be a UNC name.
If lpDirectoryName is NULL, the GetDiskFreeSpaceEx function obtains information about the disk that contains the currect directory.
Note that lpDirectoryName does not have to specify the root directory on a disk. The function accepts any directory on the disk.

· lpFreeBytesAvailableToCaller
Pointer to a variable to receive the total number of free bytes on the disk that are available to the user associated with the calling thread.
If the operating system implements per-user quotas, this value may be less than the total number of free bytes on the disk.

· lpTotalNumberOfBytes
Pointer to a variable to receive the total number of bytes on the disk.

· lpTotalNumberOfFreeBytes
Pointer to a variable to receive the total number of free bytes on the disk.
This parameter can be NULL.

Return Values
If the function succeeds, the return value is nonzero.

If the function fails, the return value is zero. To get extended error information, call GetLastError.

Examples

Related Functions

 

 


Copyright © 1998-2007, The Mentalis.org Team - Privacy statement
Did you find a bug on this page? Tell us!
This site is located at http://allapi.mentalis.org/