菜鸟笔记
提升您的技术认知

定时多次自动打开关闭网页的bat脚本

问题:

如果遇到某网页需要点击量,但是又限制,比如每10分钟内多次点击只能算一次。

解决方法:

这个时候windows批处理脚本bat的作用就来了。

新建文本文档,写入如下内容

@echo off
setlocal enabledelayedexpansion
title 浏览网页

for /l %%i in (1,1,10) do (
echo %%i
start c:\progra~1\Intern~1\iexplore.exe "https://www.baidu.com.cn"
timeout /T 61 /NOBREAK

taskkill /f /t /im iexplore.exe
)

修改适应自己的需要

{

循环次数:for /l %%i in (1,1,10)

点击事件间隔(秒):timeout /T 601 /NOBREAK

使用的浏览器和位置:start c:\progra~1\Intern~1\iexplore.exe "https://www.baidu.com.cn"

要打开的网页地址:start c:\progra~1\Intern~1\iexplore.exe "https://www.baidu.com.cn"

}

修改文件名为openclose.bat

双击执行。