+ Reply to Thread
Results 1 to 1 of 1

Moving all but the newest files from one folder to an Archive folder.

  1. #1
    Registered User
    Join Date
    03-28-2007
    Posts
    6

    Moving all but the newest files from one folder to an Archive folder.

    Hi all,

    I have been battling with a moster workbook for a while now. Having only over done rudimentary programming in Matlab before, this has been a very steep learning curve.

    Basically, I have a image analysis software that outputs text files to two specific folders (a new text file is created every 500 frames, or approx one minute). I have set up a filtering algorithm in excel to remove data for images that don't meet certain criteria.

    The macros i am using:

    1) search for the most recently modified file in each folder
    2) import the files determined to be most recent.
    3) perform a text to columns transformation
    4) calculate and summarise the filtered data
    5) output a new text file with the appropriate sumarised dat to an transfer folder where it is picked up by our Process Database.

    The macros run well initially, however as the number of files in the raw data folder increases, the program slows down significantly as it reads through the text files from oldest to newest.

    I would like to modify this code to move all but the most recent file to a different folder. I cannot simply move all files as the most recent file is generally still being written to by the imaging software.

    Attached is the code I have so far. I'm sure to your trained eyes it is very poorly written (except for some sections that have been provided for me by mudraker).
    Attached Files Attached Files

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1