Possible Duplicate:
Sort NSArray of date strings or objects
I want to sort an array which contain Dates in ascending order
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
it is a very generic way to sort any
NSArraywith any type of objects, using blocks. now, it just is specified as solution for your current problem with theNSDateobjects.please note: you can use
NSMutableArraywith-sortUsingComparator:method, which provides the same result, but the array will be sorted inside of itself.