What robocopy command copy all folders and files with original dates


  1. Posts : 759
    Microsoft Windows 7 Ultimate 64-bit 7601 Multiprocessor Free Service Pack 1
       #1

    What robocopy command copy all folders and files with original dates


    I want to copy the contents of pen drive to E drive. The pendrive drive is F. Now i want all the folders and files to have the same date it was as in the pen drive, when i stored .
    Normally when i copy, all the files retain original date but folders get todate. Meaning less if date specific creation of folder is needed.
    I heard that robocopy feature in command would give me a way to it. Reading in microsoft or in other forums, including in this forum would not solve my problem. as it is total technical in nature of using switches in command.
    My specific need is date of the folders and folder in the pendrive F to be copied to E: in one new folder, say Eendrive copy .
    Dcopy is one of the sub command. I want total command for this . There may be experts in this commands. Please let me know , how to accomplish this. The command help of microsoft only know to the tech experts, who knows all /\ switches. As a newbie to this subject, i do not know how to issue the command prompt command.
      My Computer


  2. Posts : 6,285
    Windows 10 Pro X64
       #2

    I did a Google search for your thread title: robocopy command copy all folders and files with original dates

    Got the following: What switches can robocopy use to preserve file and directory times on the target?
      My Computer


  3. Posts : 759
    Microsoft Windows 7 Ultimate 64-bit 7601 Multiprocessor Free Service Pack 1
    Thread Starter
       #3

    Probably you may be correct. The files get origianal date and not folders . Might be that i would have copied without executing the above command in the first instance when i copied the contents from pendrive to computer. should check, whether folder also retains the same old original date.
    Normally when you use explorer, it gives you, the folder modified, date modified tab, date.But looking inside, you could see the created date.
    My doubt is even normal copy does the same, then why robocopy? If you copy paste, then the folder gets the date of copying and the files there in original dates?
    Anyhow, thanks for the specific link. I my self went there, but could not understand. When you give that link, i tried, and found files in original and folders in new dates.
    When you see the folders , there is a thinking that the folders have been created only recently, if you view the explorer view.
      My Computer


  4. Posts : 759
    Microsoft Windows 7 Ultimate 64-bit 7601 Multiprocessor Free Service Pack 1
    Thread Starter
       #4

    Yes. I tried by changing the system date to 2 years back and then created folder on 3/5/2014. I also changed the date by one day 4/5/2014 and created a note file. Then i changed the date today. I tried your link and it also retains the folder date.
    So, one must be care to use that formula when one copies one drive and then format the pendrive to recopy it.
    The funniest thing is the folder shows one day ahead of the created folder, because a file was created in the folder one day later.
    Would you explain this behavior of changing the folder date by one day . Is there a connection between folder folder created date and files that are added to it. I will be waiting.

    That formula you suggested is the exact formula to retain the previous dates of folders as well as files.
    Last edited by jraju; 05 Mar 2016 at 07:29.
      My Computer


 

  Related Discussions
Our Sites
Site Links
About Us
Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

© Designer Media Ltd
All times are GMT -5. The time now is 06:28.
Find Us