cancel
Showing results for 
Search instead for 
Did you mean: 

Need to Sort a collection of Date time field

PreetamSikdar1
Level 3
Hi 

Created a collection which contains all the files and its created date as datetime.
Need to sort it with the latest or the oldest one.
How to do it?
I can write a C# code in the code stage but I am opting out that options.
and also I have another a solution to get all the date-time difference for each file.
But need other simple solution. 
Sort Ascending true false not working on Created column.

------------------------------
Preetam
------------------------------
1 BEST ANSWER

Helpful Answers

james.man
Staff
Staff
I was able to sort a collection of files based on the datetime, just by using the Utility - Collection Manipulation, Sort Collection action.

I've attached an example.  Change the file path to suit your needs.  The example will read all of the files belonging to a configurable folder path, and then sort them.

------------------------------
James Man
Professional Services
Blue Prism
Asia/Hong_Kong
------------------------------

View answer in original post

2 REPLIES 2

james.man
Staff
Staff
I was able to sort a collection of files based on the datetime, just by using the Utility - Collection Manipulation, Sort Collection action.

I've attached an example.  Change the file path to suit your needs.  The example will read all of the files belonging to a configurable folder path, and then sort them.

------------------------------
James Man
Professional Services
Blue Prism
Asia/Hong_Kong
------------------------------

Thanks
it worked fine.

------------------------------
Preetam Sikdar
------------------------------