M
MJ
We are in the process of moving to a new server and are trying to clean up
some old and very manual processes.
We currently have a batch file that is kicked off manually by a user to copy
files from our current FTP folder to a network processing folder on a
different server, i.e.:
copy \\server1\FTP\FILE01*.txt \\serverNEW\ProcessDir
copy \\server1\FTP\FILE02*.txt \\serverNEW\ProcessDir
copy \\server1\FTP\FILE03*.txt \\serverNEW\ProcessDir
....
While this currently works for copying the files, we would like to:
1) Change it to copy ALL files (EXCLUDING subfolders) in the FTP folder to
the new server;
-- Should we be using "copy" or "xcopy"?
-- Since there will be more than one day's worth of files in the FTP
folder, is there a way to keep from copying files time after time?
2) After the copy, we want to clear off (delete) files from the FTP folder
after they are older than 4 days (based on their modified date); and
-- Since multiple processes access this FTP folder, we need to leave
the files on this server until they are 4 days old and then we can remove them
3) Be able to automate it through some kind of scheduler.
One of my peers suggested that we might need to try VBScript to do this,
does anyone have any ideas/suggestions? Unfortunately they do not know
VBScript and I am the closest thing to VB programmer that we have, so I am
trying to see how we might be able to accomplish this simply and quickly.
Thanks in advance for your insight and assistance.
some old and very manual processes.
We currently have a batch file that is kicked off manually by a user to copy
files from our current FTP folder to a network processing folder on a
different server, i.e.:
copy \\server1\FTP\FILE01*.txt \\serverNEW\ProcessDir
copy \\server1\FTP\FILE02*.txt \\serverNEW\ProcessDir
copy \\server1\FTP\FILE03*.txt \\serverNEW\ProcessDir
....
While this currently works for copying the files, we would like to:
1) Change it to copy ALL files (EXCLUDING subfolders) in the FTP folder to
the new server;
-- Should we be using "copy" or "xcopy"?
-- Since there will be more than one day's worth of files in the FTP
folder, is there a way to keep from copying files time after time?
2) After the copy, we want to clear off (delete) files from the FTP folder
after they are older than 4 days (based on their modified date); and
-- Since multiple processes access this FTP folder, we need to leave
the files on this server until they are 4 days old and then we can remove them
3) Be able to automate it through some kind of scheduler.
One of my peers suggested that we might need to try VBScript to do this,
does anyone have any ideas/suggestions? Unfortunately they do not know
VBScript and I am the closest thing to VB programmer that we have, so I am
trying to see how we might be able to accomplish this simply and quickly.
Thanks in advance for your insight and assistance.