Username/Password ile Ağ Sürücüsü Map’lemek (Script)

% Scriptler Yorum Ekle

Bazı durumlarda MAP işlemini, Username ve Password bilgisi ile yapmamız gerekebilir. Bunun için aşağıdaki scripti kullanabiliriz.

Option Explicit
Dim objNetwork
Dim strDriveLetter, strRemotePath, strUser, strPassword, strProfile
strDriveLetter = "K:"
strRemotePath = "\\FileServer\Ortak"
strUser = "User35"
strPassword = "P@sswd1"
strProfile = "false"

Set objNetwork = WScript.CreateObject("WScript.Network")
objNetwork.MapNetworkDrive strDriveLetter, strRemotePath, _
strProfile, strUser, strPassword

Yorum Ekle

Wordpress - License / GPLv2
Entries RSS Comments RSS Log in