Getting sorted list of files
How can I retrieve a sorted list of files in a specific directory? I have to sort this list in different ways. I don't want to display a dialog box (like CFileDialog).
This issue is especially for a large amount of files in this directory
Who knows how to do this?
Thanks in advance
Re: Getting sorted list of files
::FindFirstFile() and ::FindNextFile() can retrieve a list of files in long filename format, including a specific set if desired ("*.TXT", "AP_*.DEF", etc) - but sorting is up to you. I'm sure there are plenty of algorithms for sorting text.
Re: Getting sorted list of files
You can use qsort function for sorting.