i want to copy files from the folder which was modified in last 2 hours. kindly provide me the batch script. i have the folder name called E:folder1 and E:folder 2. Folder1 will have more files and keep receiving in this folder. i want to copy last 2 hours files only from folder 1 and paste it in folder.
you can try with FileTimeFilter.bat :
for /f "tokens=* delims=" %%# in ('filetimefiler.bat "E:\folder1" -hh -2') do (
copy "%%~#" " E:\folder 2"
)
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.