Hello all,
I am using a listview to show a bunch of data about some files. I use sorting code provided by Microsoft (http://support.microsoft.com/default...b;en-us;319399) to be able to sort on different columns of the listview. This code uses the IComparer. Sadly, the IComparer doesn't use the smarter 'Windows XP'-way of sorting.
With XP: 2.jpg will go before 10.jpg (because the number 2 is lower than the number 10)
With the IComparer: 10.jpg will go before 2.jpg (because the character 1 is 'lower' than character 2)
The IComparer only sorts textwise, not by value. Is there an easy way to programmatically sort by value? (So that series of 0...9-characters will be seen as values, in stead of normal text.)
Thanks in advance,
Alex.




Reply With Quote