Answered
Check if a .exe program is running
Hello everyone, everything good?
How do I check if the application (.exe ) is running through script? Thanks in advance.
Hello everyone, everything good?
How do I check if the application (.exe ) is running through script? Thanks in advance.
checked on win7 cs6
var exe_name = "Roland VersaWorks.exe"
var tmp_name = "tmp.tmp"
system("tasklist >%TEMP%/"+tmp_name)
var file = new File(Folder.temp.fsName + "/" + tmp_name);
file.open("r");
var s = file.read();
file.close();
file.remove();
if (s.search(new RegExp(exe_name, "i")) >= 0)
alert(exe_name + " is running")
else
alert(exe_name + " is not running")
Already have an account? Login
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.