Thought that I would try rewording this problem in the hope that it helps me get a response (yup... still stuck on it!).
A series of files are uploaded automatically to my server with names based on the time that they were created. For example:
location1-11-07-2002-11-34-typex.csv
location1-11-07-2002-11-34-typey.csv
location1-10-07-2002-10-22-typex.csv
location1-10-07-2002-10-22-typey.csv
location2-11-07-2002-13-22-typex.csv
location2-11-07-2002-13-22-typey.csv
What I need to be able to do is to select the newest file that matches certain criteria (which is then added into a database). For example to open the newest file that matches:
location1-*-typex.csv
Although the routine that I have to read the data and add it into the database works fine I currently have to specify the file name. As these names include the time that they were created it is not possible to specify the whole name.
Can anyone offer suggestions on how I can create a variable containing the name of the newest file matching certain criteria?
Thanks in advance for any help.