Tom's Guide | Tom's Hardware | Tom's Games
![]() |
![]() |
![]() |
Hi guys,
I have a server and my laptop, and my server has all my important files. I recently wrote a small .bat file to copy the contents of a specific folder from my laptop to my (mapped) server harddrive for backup every night.
This is the jist of what it looks like... very simple.
Xcopy /s "C:\foldername\foldername" "z:\foldername"
thats it...
What I want to know is, every night when it copies... It asks on the first file, overwrite (yes,no,all)?
Is there any way that I can make the .bat automatically select no, yes, or all...
I just want it to copy the new files that I save into this folder, and It stops and asks me, and I want this to be an automatic bat file. I want it to do it with me unattended.
Can anybody help me out?
Thanks a lot,
ScizzyResponse Number 1 Reply:
/Y will automatically copy the files
/U will update the filesCheck XCOPY help for other options you may want to use.
Response Number 2 Reply:
I use these in my backup:
/s/r/y/d/c
s subdirs
r read-only
y yes
d newer only
c continue if error
M2
If at first you don't succeed, you're about average.
Sponsored Link
RecordSet help vb6
A VB Code for Printed pag... ![]()
Post LockedThis post is quite old and has been locked from receiving new replies. Please create a new posting instead.
Go to Programming Forum Home
Sponsored links
Ads by Google
Results for: .bat Automatically Overwrite ??Random Help RequiredSummary: My friends and I could do with some help ! We are an internet gaming clan and would like to write (or receive) a .bat file to do the following. Attach 1 of 9 values at random to the end of a text sent...
www.computing.net/answers/programming/random-help-required/15090.html
Bat script overwrite text fileSummary: I need help with script that shows uptime of 50 pc's. The script run once a week and it works but i would like the script to overwrite last week results. I have tried > but it doesn't write anything o...
www.computing.net/answers/programming/bat-script-overwrite-text-file/17334.html
Batch Coding - User input; responseSummary: I am writing a script the executes .exes and .bats automatically, eliminating any humna error... I have run into a snag, can anyone help? [code] @ECHO OFF :: START install start /wait install.exe set ...
www.computing.net/answers/programming/batch-coding-user-input-response/13526.html
![]()