?
Solved

Need script to copy files based on last-modified-date

Posted on 2008-10-26
1
Medium Priority
?
1,045 Views
Last Modified: 2008-10-28
I need a script that will copy files from a folder based on modified date.  In other words, I would give it a date/time such as '2008-10-26 17:08' and it would copy all files in the folder I specify which were modified after that time.

I would prefer one that looks thru subfolders as well but that's not imperative.

I know that XCOPY allows selection based on date, but I need date and time

Thanks
0
Comment
Question by:bobgato111
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 32

Accepted Solution

by:
Robberbaron (robr) earned 500 total points
ID: 22821017
http://tek-tips.com/viewthread.cfm?qid=833148

http://www.rondebruin.nl/folder.htm

the third item on second link seems the best. It uses
If Fdate >= DateSerial(2006, 10, 1)

then modify to
If Fdate >= DateSerial(2008, 10, 26) + TimeSerial(17,07,00) then  ''ie 2008-10-26 17:08'
         FileInFromFolder.Copy ToPath
        End If

0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Not long ago I saw a question in the VB Script forum that I thought would not take much time. You can read that question (Question ID  (http://www.experts-exchange.com/Programming/Languages/Visual_Basic/VB_Script/Q_28455246.html)28455246) Here (http…
Deploying a Microsoft Access application in a Citrix environment is not difficult but takes a few steps. However, Citrix system people are often of little help, as they typically know next to nothing about Access. The script provided here will take …
Monitoring a network: how to monitor network services and why? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the philosophy behind service monitoring and why a handshake validation is critical in network monitoring. Software utilized …
In this video, Percona Solutions Engineer Barrett Chambers discusses some of the basic syntax differences between MySQL and MongoDB. To learn more check out our webinar on MongoDB administration for MySQL DBA: https://www.percona.com/resources/we…
Suggested Courses
Course of the Month14 days, 2 hours left to enroll

800 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question