view-webrun.vbs
dim url, oargs
2
3 set oargs = wscript.arguments
4
5 if oargs.count = 0 then
6 msgbox("错误:必须有url")
7 wscript.quit 1
8 end if
9
10 url = oargs(0)
11
12 on error resume next
13 set objxml = createobject("msxml2.serverxmlhttp")
14
15 if err then
16 msgbox("error: " & err.description)
17 wscript.quit 1
18 end if
19
20 连接远程机器并取回页面内容
21 objxml.open "get", url, false
22
23 objxml.send()
24
25 返回结果
26 msgbox objxml.responsetext
27
28 清场
29 set objxml = nothing
