Guest User

Guest User

  • Tech Writer
  • 77
  • 13.9k

timer loop for reading csv file

Aug 11 2020 10:29 PM
Hi wanna ask, is there any way to edit this code to make it as a timer. Because I want to get last edit csv file and save it to the database, at least loop for about 30 second.
 
foreach (FileInfo file in filess)
{
   DateTime lastWriteTime = file.LastWriteTime;
   Console.WriteLine("Time last Edit : " + lastWriteTime);
}
 
thank you
 im using visual studio 2019,c#

Answers (5)