Generic Sorting Classes
You can sort any data that is stored in an indexed data storage structure such as lists, collections, and arrays of all data types, including multi-dimensional arrays and arrays of UDTs.
It is up to you to write the comparison code needed in the exposed Compare routine to suit your particular storage structure and data type.
This is actually the best approach as it hides all the sorting details and leaves you to handle only the comparison code relavant to your current data implementation and desired sort criteria.
This is not intended to be a treatise on sorting multi-dimensional arrays or arrays of UDT's, if this is what you need then psc has has some very good examples on these subjects.
This is intended as a straighforward sorting solution that may be useful if you have a specific need to sort an indexed data structure, and you would like the sorting details to be hidden, and the sorting class's usage to be as simple and as generic as possible.
Each class header has clear instructions on how to implement that particular solution, and this form's code also demonstrates the usage of each sorting class without complicating it with data implementation details.
As usual, you are free to use any part or all of this code even for commercial purposes in any way you wish under the one condition that no copyright notice is moved or removed from where it is.
Happy coding :)