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-30 02:22
中国DOS联盟论坛 » DOS疑难解答 & 问题讨论 (解答室) » Timed copy, files from a specified time View 744 Replies 1
Original Poster Posted 2006-03-21 11:40 ·  中国 四川 成都 电信
新手上路
Credits 6
Posts 1
Joined 2006-03-21 11:19
20-year member
UID 52502
Gender Male
Status Offline
Can anyone tell me a batch command that does the following:
On a 2003 system, every day at 0:00, copy the files newly created the previous day in a specific directory to an FTP server in another city
Floor 2 Posted 2006-03-21 19:58 ·  中国 湖北 荆门沙洋区 电信
荣誉版主
★★★
Credits 2,013
Posts 718
Joined 2006-02-18 07:07
20-year member
UID 50550
Status Offline
First use set /a to get the current date, then still use set /a to calculate the previous day's date, paying attention to the end-of-month case.
Then use the xcopy /d command to copy the previous day's files
Finally add this file to Task Scheduler. Although batch files do have their own delay function, it is not recommended to use it.
Forum Jump: