递归显示指定文件夹下面的文件
using System; using System.IO; class Program { static void Main() { string[] files = Directory.GetFiles("D:\\快盘\\", "*.*", SearchOption.AllDirectories); foreach (string file in files) { Console.WriteLine(file); } } }
http://www.dotnetperls.com/recursive-file-list