Sets the Volume Label of a drive.
DriveSetLabel ( "path", "label" )
Parameters
path | Path of drive to change. |
label | New volume label for the drive. (11 characters is usually max length) |
Return Value
Success: | Returns 1. |
Failure: | Returns 0. |
Remarks
Most hard drives have a maximum label length of 11 characters, and DriveSetLabel will fail if max length is exceeded. Also, FAT32 partition labels tend to revert to all capital letters.
Related
DriveGetDrive, DriveGetFileSystem, DriveGetLabel, DriveGetSerial, DriveGetType, DriveSpaceFree, DriveSpaceTotal, DriveStatus
Example
DriveSetLabel("C:\", "New_Label")