Windows上最后访问的文件?

时间:2014-01-04 01:40:04

标签: c# windows

如何通过C#检索最近打开/访问过的文件列表,而不仅仅是从打开文件对话框 MRU列表,而无需扫描整个文件驾驶?

由于

Getting the last opened file in fileopen dialog box http://www.codeproject.com/Articles/3636/Add-Most-Recently-Used-Files-MRU-List-to-Windows-A

1 个答案:

答案 0 :(得分:2)

(以公开礼貌的方式发布答案的链接,以便将其从未答复的列表中删除,因为我还没有特权。)

string path = Environment.GetFolderPath(Environment.SpecialFolder.Recent);
var files = Directory.EnumerateFiles(path);

信用到AS-CII

ORIGINAL ANSWER HERE

相关问题