I'm getting the following error:
ActiveX component can't create object.
Here's the code:
strComputer = "."
Set objWMIService = GetObject("winmgmts:{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")
Set colProcessList = objWMIService.ExecQuery("SELECT * FROM Win32_Process WHERE Name = 'Eyesistant.exe'")
For Each objProcess In colProcessList
objProcess.Terminate
It's dying on the GetObject line.
Any ideas???
ActiveX component can't create object.
Here's the code:
strComputer = "."
Set objWMIService = GetObject("winmgmts:{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")
Set colProcessList = objWMIService.ExecQuery("SELECT * FROM Win32_Process WHERE Name = 'Eyesistant.exe'")
For Each objProcess In colProcessList
objProcess.Terminate
It's dying on the GetObject line.
Any ideas???