China DOS Union

-- Unite DOS · Advance DOS · Grow DOS --

Union site: www.cn-dos.net Forum site: www.cn-dos.net/forum
DOS stands for freedom, openness and progress. Let us work hard, learn from the openness and GNU spirit of FreeDOS and Linux, and together build and grow a free GNU GPL world!

中国DOS联盟论坛
The time now is 2026-06-28 14:52
中国DOS联盟论坛 » DOS疑难解答 & 问题讨论 (解答室) » How to implement delay in batch processing View 1,307 Replies 4
Original Poster Posted 2004-12-26 00:00 ·  中国 河北 石家庄 移动
初级用户
Credits 118
Posts 7
Joined 2004-12-23 00:00
21-year member
UID 34863
Gender Male
Status Offline
When writing a batch file, the process is to download a file from FTP and then decompress it to a certain folder. But FTP download takes time. How to delay? Except for PAUSE.
Floor 2 Posted 2004-12-26 00:00 ·  中国 河北 石家庄 移动
初级用户
Credits 118
Posts 7
Joined 2004-12-23 00:00
21-year member
UID 34863
Gender Male
Status Offline
Maybe you can use IF EXIST instead of delay.
Floor 3 Posted 2004-12-26 00:00 ·  中国 上海 静安区 电信
初级用户
Credits 148
Posts 18
Joined 2004-11-30 00:00
21-year member
UID 34236
Gender Male
Status Offline
The simplest delay: ping -n 5 127.0.0.1 to achieve a 5-second delay, and you can set the delay time yourself
Floor 4 Posted 2004-12-27 00:00 ·  中国 河北 石家庄 联通
铂金会员
★★★★
网络独行侠
Credits 6,962
Posts 2,753
Joined 2003-04-16 00:00
23-year member
UID 1565
Gender Male
From 河北保定
Status Offline
The delay doesn't seem to solve the problem of the original poster. How do you know how much delay time is needed? The characteristic of batch processing is that each command is executed in sequence. The next command won't be executed before the previous one finishes. If it's related to a specific command, you can use start /wait to start a certain command (wait for it to finish executing).
偶只喜欢回答那些标题和描述都很清晰的帖子!
如想解决问题,请认真学习“这个帖子”和“这个帖子”并努力遵守,如果可能,请告诉更多的人!
Floor 5 Posted 2004-12-27 00:00 ·  中国 广东 广州 荔湾区 电信
金牌会员
★★★★
D◎$ Fαп
Credits 4,562
Posts 1,883
Joined 2004-01-19 00:00
22-year member
UID 15812
Gender Male
From 广东广州
Status Offline
I'm afraid there's no command for delay.
But you can use a third-party tool, for example, wait.com on the MSDOS 7.1 boot disk.
----====≡≡≡≡ 我的至爱,永远是MSDOS!≡≡≡≡====----
Forum Jump: