坎是跨过去的不是望过去的。

VBS判断某个进程是否启动

上一篇 / 下一篇  2011-11-21 17:20:48 / 个人分类:QTP

以百度hi进程为例:
'═════代═══码═══开═══始═════
on error resume next
set y=getobject("winmgmts:\\.\root\cimv2")
set ws=createobject("wscript.shell")
set x=y.execquery("select * from win32_process where name='BaiduHi.exe'") 
for each i in x
     msgbox "BaiduHi进程存在"
     wscript.quit
next
msgbox "BaiduHi进程不存在"
'═════代═══码═══结═══束═════

TAG:

 

评分:0

我来说两句

日历

« 2024-05-04  
   1234
567891011
12131415161718
19202122232425
262728293031 

数据统计

  • 访问量: 30403
  • 日志数: 50
  • 建立时间: 2011-07-13
  • 更新时间: 2012-08-25

RSS订阅

Open Toolbar