S
sing_cee
Unregistered / Unconfirmed
GUEST, unregistred user!
做一个新闻采集网页,用到了下面的一段VBS脚本代码 调用IE打开指定URL 10秒后自动关闭IE
url = "http://www.sohu.com/"
set ie=wscript.createobject("internetexplorer.application","event_")
ie.visible=1
ie.navigate url
WScript.Sleep 10*1000
Set wmi=GetObject("winmgmts://.")
Set pro_s=wmi.instancesof("win32_process")
For Each p In pro_s
if p.name="iexplore.exe" then
p.terminate() 'win2003 IE进程名为大写
Next
url = "http://www.sohu.com/"
set ie=wscript.createobject("internetexplorer.application","event_")
ie.visible=1
ie.navigate url
WScript.Sleep 10*1000
Set wmi=GetObject("winmgmts://.")
Set pro_s=wmi.instancesof("win32_process")
For Each p In pro_s
if p.name="iexplore.exe" then
p.terminate() 'win2003 IE进程名为大写
Next