For demo purpose I have saved the latest file name in variable and printed on screen by using Console.Write() method. Using c#, we can do this task. It is very important topic for all the startup developers.

Output

For demo purpose I have saved the latest file name in variable and printed on screen by using Console.Write() method. Using c#, we can do this task. It is very important topic for all the startup developers.

Output

Join the conversation! Your thoughts help the community grow.
Sign in to leave a comment
It is the same account you read, post and publish with — and you will come straight back to this page.
Jose PenaPosted Aug 10, 2018, 8:50 AM
Issue: This works great with local C: drive paths and just about all network paths \\nas... However there is one path location in my network where it doesn't return the correct latest filename or modified datetime. I'm using a MessageBox to confirm latest modified datetime and file name (it gives me correct "Date" but not the correct "Time"). Why is this not working for one of my network paths? I see the latest file but C# can't see it. Essentially I'm trying to get the latest filename plus extension; store it in a string variable so SSIS package can process the latest file. -- Thank you sir.
Sheikh EmaduddinPosted Feb 27, 2018, 1:13 AM
Hi, Can you please tell me how to open that file?
Rathrola Prem KumarPosted Sep 7, 2016, 10:40 PM
:)
SubashPosted Sep 7, 2016, 8:41 AM
Intresting
Guest UserPosted Aug 15, 2016, 1:18 AM
Helpful Content