How to include space in drive label using command-line MS format?

Posted by Leif Carlsen on Super User See other posts from Super User or by Leif Carlsen
Published on 2011-03-19T00:17:55Z Indexed on 2011/03/19 16:12 UTC
Read the original article Hit count: 352

Filed under:
|
|
|

The obvious-to-me approaches fail.

# format h: /fs:ntfs /q /y /V:512MB Disk
Invalid parameter - Disk

# format h: /fs:ntfs /q /y /V:"512MB Disk"
Invalid parameter - Disk"

# format h: /fs:ntfs /q /y /V:"512MB\ Disk"
Invalid parameter - Disk"

# format h: /fs:ntfs /q /y /V:512MB\ Disk
Invalid parameter - Disk

Okay, so label works after-the fact.

# label h: 512MB Disk

#

But how to do it using format? Am I missing some kind of escape sequence?

© Super User or respective owner

Related posts about Windows

Related posts about command-line