Recent

Author Topic: how to get latest file from folder  (Read 488 times)

Packs

  • Sr. Member
  • ****
  • Posts: 492
how to get latest file from folder
« on: September 03, 2024, 01:26:30 pm »
I have windows server .

I have  main folder  with subfolder . how to get latest file from folder for each employee .

this folder contains employee images .

is there any function or have to write recursive function to find employee wise latest file


Zvoni

  • Hero Member
  • *****
  • Posts: 3300
Re: how to get latest file from folder
« Reply #1 on: September 03, 2024, 01:39:43 pm »
FindFirst and its sisters
https://www.freepascal.org/docs-html/rtl/sysutils/findfirst.html
You get an "out"-Result-Record you can add to a list, array, whatever.
That record also contains the TimeStamp of the file
One System to rule them all, One Code to find them,
One IDE to bring them all, and to the Framework bind them,
in the Land of Redmond, where the Windows lie
---------------------------------------------------------------------
Code is like a joke: If you have to explain it, it's bad

 

TinyPortal © 2005-2018