title: Batch file to copy a file based on date modified
body: <p>Folder : C:\data\PRODDB\dir</p>
  
  <p>In the above folder files get created daily in the morning .I want to create a batch script which checks/identifies that folder for the latest file based on date and copy to other location ( d:\test). </p>
  
  <p>eg: file created as backup_110513.DMP  11/05/2013</p>
  
  <p>We will use a backup software to schedule a backup job to backup the files in the folder(d:\test) and after that particular file gets backed up from d:\folder, need to create another script which empties the folder d:\test.</p>
  
  <p>Thanks.</p>