Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
GetDiskFreeSpace not working
Message
De
05/12/1997 12:14:08
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Fonctions Windows API
Titre:
GetDiskFreeSpace not working
Divers
Thread ID:
00064049
Message ID:
00064049
Vues:
94
I am having trouble with GetDiskFreeSpace. I am not getting the return values. Can anyone see what I am doing wrong?


+++++++++++++++++++++++++++++++++++++++++

declare GetDiskFreeSpace in win32api as getdiskfreespace ;
STRING @ lpRootPathName, ;
LONG @ lpSectorsPerCluster, ;
LONG @ lpBytesPerSector, ;
LONG @ lpNumberOfFreeClusters, ;
LONG @ lpTotalNumberOfClusters

local lStartPath, ;
lRootPathName, ;
lSectorsPerCluster, ;
lBytesPerSector, ;
lNumberOfFreeClusters, ;
lTotalNumberOfClusters, ;
lClusterSize

lStartPath = getdir()
lRootPathName = iif(len(lStartPath) >= 3, left(lStartPath, 3), "") + chr(0)
lSectorsPerCluster = 1
lBytesPerSector = 2
lNumberOfFreeClusters = 3
lTotalNumberOfClusters = 4

if empty(lStartPath)

return && cancelled

else

if !GetDiskFreeSpace(lRootPathName, ;
lSectorsPerCluster, ;
lBytesPerSector, ;
lNumberOfFreeClusters, ;
lTotalNumberOfClusters)

return && error

endif

endif
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform