How do I get a list of drive letters and their associated labels on a windows system through a bat file?
Windows – How to get a list of drive letters on a system through a windows shell (bat, cmd)
batch-filewindowswindows-command-prompt
Related Topic
- Windows – Recursive CMD or BAT Windows Script
- Windows – How to get system locale in Windows 7 cmd
- Windows – Access a Network drive from another user from CMD (windows)
- Windows – how to get default gateway of certain adapter in windows bat
- Windows – How to create an ODBC connection from .bat file in Windows
- Windows Batch File – How to Sleep in a Batch File
Best Answer
This will get most of it:
If you have any drives mapped via subst you would also need to get those:
For completeness, you would do it like this in Powershell (if you are on windows 7 or have installed it):
You can also do it from the command prompt or a batch file using WMI like this: