I was wondering, is there an easy way to sort a CList, CArray etc ? I initially figured that there would be some sort (hehe) of sort() function like there is for STL vector, but there is not. In fact there is nothing even resembling this. I really don't want to have to write my own sorting algorithm as this feels a bit like re-inventing the wheel.
I thought about possibly cheating a bit, by creating a STL vector, copying the CList elements into it, sorting the vector in the normal STL way and then copying the elements back to the CList. As good as this sounds I have no idea if it would be excepted to mix STL with MFC; indeed if it is possible or not.
Do we mix STL components with MFC or not, and if not how can I sort my CList ??
Thanks in advance.