From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
I have a program that needs to automatically take data from a text file made earlier. There are several text files in a certain directory, and i need the program to take the newest file. The text files are labeled as so:
mm-dd-yyyy-time.txt ex: 12-21-2001-0813.txt
now, is there a way to read file names in a directory? or, does labview have a function that can return a file name given "modified" date?
any suggested plan of attack is greatly appreciated.
In LV6 (i'm not sure for earlier versions) in File I/O - > Advanced File Functions palette, you have "List Directory" and "File/Directory Info" ... so, exactly what you are looking for.
Hope this helps
p.s.: a suggestion would be the yyyy-mm-dd-time.txt format ... especially if you are using the explorer to access them too