Set objWMIService = GetObject("winmgmts:{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")
Set objLocator=CreateObject("WbemScripting.SWbemLocator")
Set objWMIService=objLocator.ConnectServer(strComputer, "root\default", "domain\remoteuser", "remotepassword")
Set objLocator=CreateObject("WbemScripting.SWbemLocator")
Set objWMIService=objLocator.ConnectServer(strComputer, "root\CimV2", "domain\remoteuser", "remotepassword")
strPassword = ""
For intChr = 1 To Len(strPassed)
If intChr = 1 Then
strPassword = Chr(Asc(Mid(strPassed, intChr, 1)) + 64)
Else
strPassword = strPassword & Chr(Asc(Mid(strPassed, intChr, 1)) + 64)
End If
Next
Open in new window