1个回答
展开全部
Do
If Not ProcessExists("A.exe") Then
CreateObject("Wscript.Shell").Run "C:\A.exe",0
End If
Wscript.Sleep 1000
Loop
Function ProcessExists(ProcessName)
ProcessExists = False
set WMI=GetObject("winmgmts:\\.\root\cimv2")
set Process=WMI.ExecQuery("select * from win32_process where name='" & ProcessName & "'")
For Each ID In Process
ProcessExists = True
Next
End Function
有问题追问!
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询