List of disk drives on Windows?
Tim Golden
mail at timgolden.me.uk
Tue May 20 15:45:15 EDT 2008
Bob Greschke wrote:
> This MUST have been asked before, but I can't seem to Google the right
> thing. How can I get a list of drives on a Windows box, like ["C:\",
> "D:\"], like I can if I do something like listdir("/Volumes") on a Mac?
A couple of options to get the ball rolling:
1) win32api.GetLogicalDriveStrings()
2) http://timgolden.me.uk/python/wmi_cookbook.html#find-drive-types
TJG
More information about the Python-list
mailing list