Click to See Complete Forum and Search --> : Copy function in VB6
sharpsone
Jan 4th, 2001, 02:54 PM
I need to find out how to copy a folder to a destination but have the copy process compare the source and destination only copying files that have been modified. I know you can do this in dos with XCOPY. Is their a way I can call an XCOPY dos command to do this if so HOW? I would prefer a VB way but I just don't know how to start.
alex_read
Jan 5th, 2001, 06:01 AM
What about the filesystem object ?
One of the methods of this is GetFileVersion.
You could use an if...then statement to check if the version you are copying is older, and if so to then copy the file.
Put all this in a do...while filename <> "" loop to check through all of the files in the folder for the versions, then to copy as neccessary.
This is probalbly not the best suggestion, but I hope it helps if no-one else posts here. :cool:
vbforums.com
Copyright Internet.com Inc., All Rights Reserved.