Loading |
VBScript |
JavaScript |
Powershell |
Search Options: Add a Volume Mount PointContent of Add a Volume Mount Point.vbsMD5 Hash: 8B35E6A29624B4DC8DDFBC03E103C783 |
||
' Description: Adds a new volume mount point for the folder W:\Scripts. Note that in the WQL query, you must use two slashes rather than one, and you must also include two slashes at the end of the folder path. Thus the folder X:\Scripts\WMI would be listed as X:\\Scripts\\WMI\\.
strComputer = "." Set objWMIService = GetObject("winmgmts:" _ & "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2") Set colItems = objWMIService.ExecQuery _ ("Select * From Win32_Volume Where Name = 'D:\\'") For Each objItem in colItems objItem.AddMountPoint("W:\\Scripts\\") Next | ||
© 2008 - 2013 Boris Toll :: Scripts available: 6.481 :: :: scriptbox.toll.at :: :: powered by www.toll.at :: |