中国DOS联盟论坛

China DOS Union

-- Unite DOS · Advance DOS · Grow DOS --
Union site: www.cn-dos.net Forum site: www.cn-dos.net/forum
Guest | Log in | Register | Members | Search | China DOS Union
中国DOS联盟论坛
The time now is 2026-09-23 14:38
47,812 topics / 349,917 posts / today 0 new / 48,273 members
DOS批处理 & 脚本技术(批处理室) » [Help] Ask why my batch script that opens multiple web pages can only open one web page
Printable Version  3,151 / 8
Floor1 tired_bird Posted 2004-11-03 00:00
中级用户 Posts 58 Credits 307
I would like to ask why my batch script that opens multiple web pages can only open one web page?

I executed the following batch script
@echo off
set ie="C:\Program Files\Internet Explorer\IEXPLORE.EXE"
%ie% www.cn-dos.net/dosbbs/list.asp?boardid=9
%ie% www.lasg.ac.cn/cgi-bin/forum/leoboard.cgi
%ie% bbs.chinaunix.net/forum/viewforum.php?f=24
:: ... Add all the websites you need to open in the above way
set ie=
exit
As a result, after executing for a long time, only the first web page is opened, and the DOS command port keeps flashing and does not close.
While in another DOS window, I can use the command to open the above websites one by one?
Why? I hope for your advice, thanks in advance!
Floor2 Climbing Posted 2004-11-03 00:00
铂金会员 Posts 2,753 Credits 6,962 From 河北保定
Add the start command before %ie% in each line, for example:
start %ie% www.cn-dos.net/dosbbs/list.asp?boardid=9
Floor3 tired_bird Posted 2004-11-03 00:00
中级用户 Posts 58 Credits 307
I just tried your method, and the result is that only the last website can be opened, and this website will also overwrite the first website I opened before executing this batch processing. Why? I hope you can give me some advice. I tested it under win2000.
Floor4 JonePeng Posted 2004-11-04 00:00
金牌会员 Posts 1,883 Credits 4,562 From 广东广州
What the person above said is right. I tried it, and it should be changed to the following:
@echo off
set ie=start C:\Progra~1\Intern~1\IEXPLORE.EXE
%ie% www.cn-dos.net/dosbbs/list.asp?boardid=9
%ie% www.lasg.ac.cn/cgi-bin/forum/leoboard.cgi
%ie% bbs.chinaunix.net/forum/viewforum.php?f=24
Pay attention! I changed the original folder names "Program Files" and "Internet Explorer" in the line "SET IE=" to the short filename format to make it work.
Floor5 JonePeng Posted 2004-11-04 00:00
金牌会员 Posts 1,883 Credits 4,562 From 广东广州
This batch script calls IE to open a web page. But as for me personally, I really dislike using IE, this "resource hog"! I suggest the thread starter use Maxthon (Aoyou) or MyIE2 to surf the web. There is an item called "Quick Group" in the menu of this browser, which can arbitrarily add multiple web pages to open at one time. Later, as long as you click the mouse, several web pages will come out one after another.
Floor6 tired_bird Posted 2004-11-04 00:00
中级用户 Posts 58 Credits 307
Thanks to JonePeng, but "Attention, I changed the original folder names Program Files and Internet Explorer in the line "SET IE=" to the short filename format to make it work. "Why didn't my method work? What's the reason? If you can explain it, it would be perfect.
Floor7 JonePeng Posted 2004-11-05 00:00
金牌会员 Posts 1,883 Credits 4,562 From 广东广州
Hehe, because your batch processing runs under DOS, and DOS does not support long folder names (I tried it in the command prompt of XP, and it also doesn't support), so it has to be changed to the short file name format. If you don't change it to the short file name format, then that batch processing will execute like this: start c:\Program Files\Internet Explorer.exe www.cn-dos.net, and a prompt box will pop up: something like "can't find Program" and so on. Also, in the command prompt of Win2000/XP, the folder names you see are all in long format. So how to display the short format? You just need to type DIR /X /AD to see it. For example, Program Files is displayed as Progra~1, Document and Settings becomes Docume~1, and so on.
Floor8 Climbing Posted 2004-11-05 00:00
铂金会员 Posts 2,753 Credits 6,962 From 河北保定
It's not because of the long filename, but because of the command-line parameters of the Start command. The Start command treats the content enclosed in the first pair of double quotes as the title line, so the command line of IE is treated as the title line, which will obviously cause problems. The original batch script should be modified as follows:
@echo off
set ie=start "Internet Explorer" "C:\Program Files\Internet Explorer\IEXPLORE.EXE"
%ie% www.cn-dos.net/dosbbs/list.asp?boardid=9
%ie% www.lasg.ac.cn/cgi-bin/forum/leoboard.cgi
%ie% bbs.chinaunix.net/forum/viewforum.php?f=24
:: ... Add all the websites you need to open in the above way
set ie=
exit
In addition, I also recommend using Maxthon (MyIE2) to replace IE. Its shortcut groups are much more convenient than this batch script.
Floor9 tired_bird Posted 2004-11-05 00:00
中级用户 Posts 58 Credits 307
[ Contact the Union admin team - 中国DOS联盟 - Standard version ]
Sponsored by ifanr Inc | © 2001–2023