fiNAL.Y
2007-09-12 21:08:01 UTC
Hi,
I have the following script:
strComputer = "someip"
strUser = "user"
strPassword = "password"
Set objSWbemLocator = CreateObject("WbemScripting.SWbemLocator")
Set objSWbemServices = objSWbemLocator.ConnectServer(strComputer, "root
\cimv2", strUser, strPassword)
Set colSwbemObjectSet = objSWbemServices.ExecQuery("Select * From
Win32_Process")
For Each objProcess in colSWbemObjectSet
Wscript.Echo "Process Name: " & objProcess.Name
Next
and it failed with Access Denied (Code: 80070005) every time.
The target machine is running Windows Server 2003 and my machine is
running XP Pro SP2
I'm running the script as administrator and the remote user on the
target machine is a member of the Administrators group. Neither of the
two machines is in a domain and they're in different workgroups.
Can any one help me with this ? Thanks very much.
I have the following script:
strComputer = "someip"
strUser = "user"
strPassword = "password"
Set objSWbemLocator = CreateObject("WbemScripting.SWbemLocator")
Set objSWbemServices = objSWbemLocator.ConnectServer(strComputer, "root
\cimv2", strUser, strPassword)
Set colSwbemObjectSet = objSWbemServices.ExecQuery("Select * From
Win32_Process")
For Each objProcess in colSWbemObjectSet
Wscript.Echo "Process Name: " & objProcess.Name
Next
and it failed with Access Denied (Code: 80070005) every time.
The target machine is running Windows Server 2003 and my machine is
running XP Pro SP2
I'm running the script as administrator and the remote user on the
target machine is a member of the Administrators group. Neither of the
two machines is in a domain and they're in different workgroups.
Can any one help me with this ? Thanks very much.