How do I copy all files from one folder to another folder - but only copy files that are newer to the 2nd folder
Posted on 2008-10-18
I need to use VB.net Visual Basic 2008.
I have 2 folders.
Each folder has a bunch of .jpg files.
How do I copy all the files from one folder to another folder -
and have it only copy the files that are NEWER to the 2nd folder?
Get all the file attributes and look at the Date modified for the attribute used to copy the folder.
Sometime there will be 2 files w/ the same name in both folders.
I want to update the folder2\*.* files with the newer ones from folder1\*.*
I am not trying to Sync the folders - just update Folder2.
I am new to VB - I think this is easy - but I am really having a hard time.
I know how to copy the folders w/ a dialog - but it will just prompt me to over write them.
I don't know how to use attribute
I think I have to build a list of the files in each folder - then compare the 2 lists - and only copy the newer ones.
Please help me.