监控程序:
on error resume next
'monitor the process running or not
set y=getobject("winmgmts:\\.\root\cimv2")
set ws=createobject("wscript.shell")
set x=y.execquery("select * from win32_process where name='xxxx.exe'")
for each i in x
wscript.quit
next
'run the process
ws.run "C:\xxxx.exe"