Loading |
VBScript |
JavaScript |
Powershell |
Search Options: Rename a VolumeContent of Rename a Volume.vbsMD5 Hash: 2E065E055E5FB8770B0B6CCFFCAD36CD |
||
' Description: Changes the volume label for drive C to "Finance Volume."
strComputer = "." Set objWMIService = GetObject("winmgmts:" _ & "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2") Set colDrives = objWMIService.ExecQuery _ ("Select * from Win32_LogicalDisk where DeviceID = 'C:'") For Each objDrive in colDrives objDrive.VolumeName = "Finance Volume" objDrive.Put_ Next | ||
© 2008 - 2013 Boris Toll :: Scripts available: 6.481 :: :: scriptbox.toll.at :: :: powered by www.toll.at :: |