Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Finding a Volume Label
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00626993
Message ID:
00627001
Vues:
16
Jeff,
1. To get the volume label, you could try:
ADIR(laDir,"D:\","DV")
2. FOPEN(, 10) and FILETOSTR() should work with files on a CD.

HTH
>I have a program that uses low-level file functions to catalog files found on a CD-ROM drive. I have two questions.
>
>#1 - how do I find the volume label of a drive? I found this on the KB but am not able to turn it around to tell me what the current volume is.
>
> DECLARE INTEGER SetVolumeLabel IN Win32API STRING lcRootPath,;
> STRING lcVolumeLabel
>
> liRetVal = 0
> * Message box with OK/Cancel buttons
> liRetVal = MESSAGEBOX("Insert scratch floppy disk in drive A:",;
> 1)
>
> * Handle non-OK selection from message box
> IF liRetVal # 1
> RETURN
> ENDIF
>
> lcVolumeLabel = "Test"
> = SetVolumeLabel ("A:\", lcVolumeLabel)
>
>#2 - How can I FOPEN(cfilename,10) &Read_Only Un_buffered a file on a CD-ROM to read the files. I had to work around this problem by copying the file to the HD before fopen()'ing it.
>
>TIA
Daniel
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform