远程最头疼的就是网断了。。。
任务计划程序控制vbs脚本的触发时间。
为了简单,我直接让网站记住密码了,打开后直接登录就行。就不用获取往里填密码了。
Dim username,password,IE '定义变量
username = "xx" ' 输入用户名
password = "xx" '输入密码
Set IE =CreateObject("InternetExplorer.Application") '调用IE程序
ie.FullScreen=0 '全屏化IE对象
IE.Visible = True '窗口可视化
IE.Navigate "xxx" '打开登录网站
Do while IE.ReadyState<> 4 or IE.busy '用循环语句确保网页加载完毕才执行下面操作
wscript.sleep 2000 '设置延迟2000ms
loop
'IE.document.querySelector("DDDDD").value=username '修改(传入)账户
'IE.document.querySelector("upass").value=password '修改(传入)密码
IE.document.querySelector(".btn").onclick '模拟次登陆键