Hi guys,
I managed to write this script to open a link in internet explorer close it and open another one.
I would like to have all my links in a different txt files with multiple links line by line and be able to do the same function reading it from the bat file
I will appreciate anybody that can help me with this.
This is the bat file I made which works great. It opens these two llinks one at a time and do some stuff.
@echo off
start /MIN iexplore.exe www.website1.com
ping 192.178.1.1 -w 1
ping 192.178.1.1 -w 1
ping 192.178.1.1 -w 1
ping 192.178.1.1 -w 1
ping 192.178.1.1 -w 1
ping 192.178.1.1 -w 1
ping 192.178.1.1 -w 1
tskill iexplore /A
RunDll32.exe InetCpl.cpl,ClearMyTracksByProcess 255
start /MIN iexplore.exe www.website2.com
ping 192.178.1.1 -w 1
ping 192.178.1.1 -w 1
ping 192.178.1.1 -w 1
ping 192.178.1.1 -w 1
ping 192.178.1.1 -w 1
ping 192.178.1.1 -w 1
ping 192.178.1.1 -w 1
ping 192.178.1.1 -w 1
ping 192.178.1.1 -w 1
tskill iexplore /A
RunDll32.exe InetCpl.cpl,ClearMyTracksByProcess 255
Thank you very much
Reading Txt Files From Bat File
Moderator: DosItHelp
Re: Reading Txt Files From Bat File
This is untested:
url.txt
www.google.com
bbc.co.uk
nbc.com
Code: Select all
@echo off
for /f "delims=" %%a in (url.txt) do (
start "" /MIN iexplore.exe "%%a"
ping -n 30 localhost
tskill iexplore /A
RunDll32.exe InetCpl.cpl,ClearMyTracksByProcess 255
)
pause
url.txt
www.google.com
bbc.co.uk
nbc.com
Re: Reading Txt Files From Bat File
That worked like a charm! thank you very much