Scripts Thread, Is Process Running in Coding and Web Development; Does anybody have a script which checks if a process is running and does an output depending on that?
25th February 2013, 04:03 PM #1
Is Process Running
Does anybody have a script which checks if a process is running and does an output depending on that?
I.e - is xx.exe running - no do this yes do that?
I know how to do it for If Exist etc but is it possible?
If *something* process.exe goto ABC else goto EFG
25th February 2013, 04:06 PM #2
That kind of thing?
set service = GetObject ("winmgmts:")
pFound = False
for each Process in Service.InstancesOf ("Win32_Process")
If Process.Name = "notepad.exe" then
pFound = True
If pFound = true then
25th February 2013, 04:21 PM #3
Erm yes - although I have just realised i could simply do - taskkill process.exe then do what i want to do anyway as it doesn't make a difference if the process is killed before what i need to do!
By Jake in forum How do you do....it?
Last Post: 13th April 2013, 03:36 PM
By jack0w in forum O/S Deployment
Last Post: 9th April 2010, 11:44 AM
By freaky_seb in forum Windows
Last Post: 19th June 2009, 03:05 PM
By FN-GM in forum Scripts
Last Post: 1st June 2008, 09:09 PM
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)