📌  相关文章
📜  Directory.GetFiles(folder, "*.dll").Select(fn => new FileInfo(fn)).OrderBy - 任何代码示例

📅  最后修改于: 2022-03-11 14:55:24.384000             🧑  作者: Mango

代码示例1
[System.Runtime.InteropServices.DllImport("Shlwapi.dll", CharSet = System.Runtime.InteropServices.CharSet.Unicode)]
private static extern int StrCmpLogicalW(string psz1, string psz2);
DirectoryInfo di = new DirectoryInfo(path);
FileInfo[] arrFi = di.GetFiles("*.*");
Array.Sort(arrFi, delegate(FileInfo x, FileInfo y) { return StrCmpLogicalW(x.Name, y.Name); });