Operating System Processes Processes and Threads List the Scripts Running on a Computer , WMI
' List the Scripts Running on a Computer
strComputer = "." Set objWMIService = GetObject("winmgmts:" _ & "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")
Set colProcesses = objWMIService.ExecQuery _ ("SELECT * FROM Win32_Process WHERE Name = " & _ "'Wscript.exe' OR Name = 'Cscript.exe'") If colProcesses.Count = 0 Then Wscript.Echo "No scripts are running." Else For Each objProcess in colProcesses Wscript.Echo objProcess.CommandLine Next End If
|
VbsEdit includes all these samples!
Download Now!
Version 5.4.1 - This package includes VbsEdit 32-bit, VbsEdit 64-bit, HtaEdit 32-bit and HtaEdit 64-bit. The evaluation version never expires.
Home
Buy Now
HtaEdit
Support
Video
What's new ?
|