Do I have to list all of the files and sort it by date and time or is there any other way?
TIA
Printable View
Do I have to list all of the files and sort it by date and time or is there any other way?
TIA
to get latest, you can just loop using dir
vb Code:
mypath = "c:\test\" f = dir(mypath & "*.*") do while len(f) > 0 if filedatetime(mypath & f) > filestetime(latest) then latest = mypath & f f = dir loop msgbox "newest file in directory is " & dir(latest)