using System.Collections.Generic;
public static void Main()
foreach (var f in GetNewOrUpdatedFiles(".", "*.pdf", DateTime.Now))
public static List<string> GetNewOrUpdatedFiles(string path, string pattern, DateTime lastCheck)
DirectoryInfo dir = new DirectoryInfo(path);
throw new DirectoryNotFoundException("The path does not exist.");
FileSystemInfo[] nfos = dir.GetFileSystemInfos(pattern);
where nfo.LastWriteTime > lastCheck
select nfo.FullName).ToList();