Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

25 lines
449 B

Dim s
Dim sink
Sub MYSINK_OnCompleted(iHResult, objErrorObject, objAsyncContext)
WScript.Echo "Done"
End Sub
Sub MYSINK_OnObjectReady(objObject, objAsyncContext)
WScript.Echo (objObject.Name)
End Sub
Set s = GetObject("winmgmts:")
Set sink = WScript.CreateObject("WbemScripting.SWbemSink", "MYSINK_")
s.Security_.ImpersonationLevel = 3
s.InstancesOfAsync sink, "Win32_process"
WScript.Echo "Hanging"