This one sounds duplicate, but all the solutions given is not satisfying one of the requirement that is sorting by name. for instance
J A1
J A2
J A3
J A10
J A11
The method returns J A1,J A10, J A11, J A2, J A3. But this is not expected as operating system sort them in a different way.
below solutions have tried already
var sorted = dirInfo.GetDirectories("*.*", SearchOption.TopDirectoryOnly).OrderBy(f => f.Name);
Array.Sort();