I\'m trying to figure out the best way to custom sort a List. Lets say that T is a Object with a date(DateTime?) property and a status(string) property.
I have 3 cases.
You could just use an extension method:
Something like this...
public static IOrderedEmumerable OrderForDisplay (this IEnumerable input) { return input .OrderBy(item => item.Status) .ThenByDescending(item => item.Status == 1 ? DateTime.MaxDate : item.date); }