Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to Identify the newest file in a directory

Status
Not open for further replies.

captphan

Programmer
Jan 24, 2007
42
I need to get the name of the file that has been most recentely saved into a folder.
Twice a day a file is added to a folder. It always have the same naming convention and all the files in the folder have the same convention.

NameDate_Date_Time

I am trying to automate a process that currently has the user selecting the file to import. How do I retrieve the name of this new file.
 
You may find the FileDateTime Function useful; check it out in VBA help.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top