J
Jake104E
I want to detect if a given program (App) is running.
I have made the following VB-Script to list all "programs" running:
Sub ListPGMs
Dim WMIService
Dim ProcessList
dim objSWbemObject
Set WMIService = GetObject("winmgmts:" & "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")
Set ProcessList = WMIService.ExecQuery ("SELECT * FROM Win32_Service")
For Each objSWbemObject In ProcessList
call Append_to_LogFile("Name: " & objSWbemObject.Name, "PGMlist.txt")
Next
end sub
Append_to_LogFile is just a utility that writes to a txt-file.
I get a lot of names in this file - like all the background and windows processes - but I can't identify the Apps that I have running.
How do I do that?
Continue reading...
I have made the following VB-Script to list all "programs" running:
Sub ListPGMs
Dim WMIService
Dim ProcessList
dim objSWbemObject
Set WMIService = GetObject("winmgmts:" & "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")
Set ProcessList = WMIService.ExecQuery ("SELECT * FROM Win32_Service")
For Each objSWbemObject In ProcessList
call Append_to_LogFile("Name: " & objSWbemObject.Name, "PGMlist.txt")
Next
end sub
Append_to_LogFile is just a utility that writes to a txt-file.
I get a lot of names in this file - like all the background and windows processes - but I can't identify the Apps that I have running.
How do I do that?
Continue reading...