I'm probably in the wrong place, but..
im trying to do use the date switch with xcopy to enable me to copy files that changed on a specific date to a different location, anybody know how it works?
I keep getting " Invalid number of parameters"
What command line are you using? If you drop to dos and type xcopy /? it will tell you the proper format and use of the command and switches. I tried using the command and had no problems. I created 2 folders on my c: drive, created a text document in one and then dropped to DOS and used Xcopy to copy the file to the second folder. The line I used was: xcopy c:\a c:\b /D:04-02-2002 (be sure not to have a space in between the : and the date, or you will get the invalid number of parameters message).
For others who may be new to using XCOPY, the /M and /A switches are worth getting familiar with. When a file gets modified, the Archive attribute gets set to A (you can see this using the ATTRIB command or from Explorer under Properties for the file). You can use this attribute to tell XCOPY to copy only those files that have changed.
Lets say you've got an empty folder. You create 10 new files in it. They will all have the "A" attribute set. Usethe command:
XCOPY /M c:\source\*.* c:\dest
All of the files will be copied and the "A" attribute cleared. Now go modify 2 of the files, and rerun the same command. Only the 2 files that changed will be copied. (The /A switch does the same thing but does NOT reset the "A" attribute).
If you're working with alot of files, this is a nice way to reduce the copy time. Put the commands in a script and you got a kind of poor-man's incremental backup. ------------------------
Doug J.
Winchester, VA
When using XCOPY, is there a way to copy files before a certain date rather than after a certain date? I know using the /D switch allows you to copy after a certain date, but what about before?
Acutally.. XXCOPY is freeware for personal use only. Any corporate use slaps a 20$ per copy license after your 60 day trial period. We just did a study on all our current software in use for license fees... But for 20$, it's a good expense if it's only on one server.
"In space, nobody can hear you click..."
Yes, for 20$, XXCOPY will do it (if it's for a business) and for free if it's home use.. but I'm not sure if the home version has all the features enabled...
"In space, nobody can hear you click..."
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.