Sort an Array of Strings containing Dates by Date

Hey guys, i haven an Array of Strings which are Dates like this:
{“31.12.2018”, “21.12.2017” “31.11.2018” “22.02.2014” “01.08.2019”}

Do you have an idea how I can sort them by Date, beginning with the lowest one. In the Example the new Order should start with “22.02.2014” and end with “01.08.2019”

Thank you a lot!

1 Like


Please check below thread.

1 Like

You can sort within an assign activity:
arrDateStrings.OrderBy(Function (s) Date.ParseExact(s,“dd.MM.yyyy”, CultureInfo.InvariantCulture)).ToArray

returning a string Array

Feel free to adopt the DateParse Details
Kindly note: 31.11.2018 is not a valid date as 30th is last Nov day, so it would crash


here you go with a xaml
hope its resolved (2.1 KB)

Cheers @Lorenz_Goring

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.