Directory.GetFiles(dirPath, "*", SearchOption.AllDirectories)
string[] allfiles = Directory.GetFiles("path/to/dir", "*.*", SearchOption.AllDirectories);
string[] entries = Directory.GetFileSystemEntries(path, "*", SearchOption.AllDirectories);