Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Determine Available Drives
Message
 
To
22/10/2003 11:06:03
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00841069
Message ID:
00841083
Views:
21
>I would like to populate a list with the drive letters of availble disk drives and shared drives. Is there a way to do this?
>
>Thanks in advance for you help,
Russell,

Martin has given you the method that I would use, however, the WSH is not always an option. If it's not in your case, then I'd recommend either GetLogicalDrives() or GetLogicalDriveStrings() in the API. The former returns an integer and by using the bit-manipulation functions in VFP you can determine which bits are set. These correspond to the available drives. The latter populates a string passed by reference with a CHR(0) delimited list of available drives.

If either is of interest, just let me know.
George

Ubi caritas et amor, deus ibi est
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform