[Solved] Stable sort with OrderBy [closed]


you can order by the key like this :

var ordered = lstValuesTemp.OrderBy(v => v.Key);

or you can order with fonction

declare the function like this:

public static string CustomOrder(KeyValuePair<string, List<string>> item)
{
    //TODO: add some logic that return a string to compare this item
}

and than call thia function:

var ordered = lstValuesTemp.OrderBy(CustomOrder);

solved Stable sort with OrderBy [closed]