Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Get Volume Information
Message
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Fonctions Windows API
Titre:
Get Volume Information
Versions des environnements
Visual FoxPro:
VFP 8 SP1
OS:
Windows XP SP2
Database:
Visual FoxPro
Divers
Thread ID:
00961460
Message ID:
00961460
Vues:
48
Hi all,

I have been trying to retrieve the volume label information from my C: drive without success.

I am using the GetVolumeInformation API call in the following manner:
clear
declare short GetVolumeInformation in kernel32;
	string lpRootPathName,;
	string @ lpVolumeNameBuffer,;
	integer nVolumeNameSize,;
	integer @ lpVolumeSerialNumber,;
	integer @ lpMaximumComponentLength,;
	integer @ lpFlags,;
	string @ lpFileSstemNameBuffer,;
	integer nFileSystemNameSize
	
cRoot='C:'
cVolumeName=''


x=GetVolumeInformation(cRoot,cVolumeName,0,0,0,0," ",0)
? cVolumeName	
? 'Return value '
?? x
The return value is always zero indicating that the call failed, only I can't figure out what I am doing wrong. Any help would be greatly appreciated.

Thanks
Vince
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform