Sürücüye Map Etme İşlemi
Aşağıdaki script kullanılarak birden fazla paylaşıma açılmış olan klasörü map yapabiliriz.
Örneğimizde, Server altındaki Share1, Share2 ve Share3 klasörlerini X, Y ve Z sürücü harflerine atadık.
Option Explicit
Dim objNetwork, strRemotePath1, strRemotePath2, strRemotePath3
Dim strDriveLetter1, strDriveLetter2, strDriveLetter3
Dim objNetwork, strRemotePath1, strRemotePath2, strRemotePath3
Dim strDriveLetter1, strDriveLetter2, strDriveLetter3
strDriveLetter1 = “X:”
strDriveLetter2 = “Y:”
strDriveLetter3 = “Z:”
strRemotePath1 = “\\Server\Share1”
strRemotePath2 = “\\Server\Share2”
strRemotePath3 = “\\Server\Share3”
strDriveLetter2 = “Y:”
strDriveLetter3 = “Z:”
strRemotePath1 = “\\Server\Share1”
strRemotePath2 = “\\Server\Share2”
strRemotePath3 = “\\Server\Share3”
Set objNetwork = CreateObject(“WScript.Network”)
objNetwork.MapNetworkDrive strDriveLetter1, strRemotePath1
objNetwork.MapNetworkDrive strDriveLetter2, strRemotePath2
objNetwork.MapNetworkDrive strDriveLetter3, strRemotePath3
objNetwork.MapNetworkDrive strDriveLetter1, strRemotePath1
objNetwork.MapNetworkDrive strDriveLetter2, strRemotePath2
objNetwork.MapNetworkDrive strDriveLetter3, strRemotePath3
Yorumlar