Click here to Skip to main content
15,897,273 members

Comments by babli3 (Top 168 by date)

babli3 27-Jan-16 7:54am View    
Hi Ryan,

public static FileInfo GetNewestFile(DirectoryInfo directory)
{
return directory.GetFiles()
.Union(directory.GetDirectories().Select(d => GetNewestFile(d)))
.OrderByDescending(f => (f == null ? DateTime.MinValue : f.LastWriteTime))
.FirstOrDefault();
}

FileInfo newestFile = GetNewestFile(new DirectoryInfo(@"C:\Log"));

This code will give me the latest downloded log file . now I have to read the contents from this file and pick the max id from it.

Can you please suggest how I can achieve this.

Thanks
babli3 29-Oct-14 8:57am View    
Thanks This has beedn resolved now.
Web service was no longer using SSL3 instead we had to use Tls.
Thanks for your responses.
babli3 22-Sep-14 5:00am View    
Thank You
babli3 16-Sep-14 6:06am View    
ok thank you. will try this
babli3 16-Sep-14 5:25am View    
Hi
vs 2013 express and classic asp