Hi guys, i'm brand new on the forum and obviosly i have some question in witch i hope to get answers.
c:\Live\document.txt
c:\Backup\
So, i want to make a logoff script that cals this bat file that i want to do the next thing: i want to copy document.txt from c:\live into c:\backup\ and overwrite the c:\backup\document.txt only if c:\livedocument\document.txt is older with atleat 7 days than docment.txt from backup folder. Thanks in advance
if c:\live\document.txt older than c:\backup\document.txt with atleast 7 days
copy if c:\live\document.txt c:\backup\document.txt
Overwrite if older
Moderator: DosItHelp
-
- Expert
- Posts: 391
- Joined: 19 Mar 2009 08:47
- Location: Iowa
Can be done with custom batch script -- but xcopy will already do it (not that I like xcopy), or, much better, use robocopy. Free from Microsoft in the resource kit. Great tool and it'll do exactly what you want (I'll bet).
http://ss64.com/nt/robocopy.html
http://www.microsoft.com/downloads/deta ... 8c4790cffd
http://ss64.com/nt/robocopy.html
http://www.microsoft.com/downloads/deta ... 8c4790cffd