DIALNAME = "xxx"
DIALUSER = "xxx"
DIALPASS = "xxx"
Set WshShell = CreateObject("WScript.Shell")
RetCode = WshShell.Run("ping www.baidu.com", 0, true)
If RetCode <> 0 Then
WshShell.Run "rasdial " & DIALNAME & " /DISCONNECT", 0, true
WScript.Sleep(3000)
WshShell.Run "rasdial " & DIALNAME & " " & DIALUSER & " " & DIALPASS, 0
WScript.Sleep(3000)
End If
posted on 2009-11-09 13:40
w2001 阅读(261)
评论(0) 编辑 收藏 引用