Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations GregLocock on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

VB6 Sorting records

Status
Not open for further replies.

derrick

Computer
Jun 13, 2001
40
I need to read a file containing about 250,000 records, sort them, and write the resulting list to another file.

List boxes are restricted to an index of 32,767. Although I can enter more items in a sorted listbox and refer to them in order by reading the first index, then deleting it so that the next list item is available, the sorting is far too slow.

Is an array of records using a sorting algorithm the best answer?

Any brillaint solutions anyone?
 
Replies continue below

Recommended for you

I've never done it, but I believe that ADO can read text files as a recordset. This then provides access to the ADO sorting and recordset handling capabilities. Mayble this would help.

Alternatively, unless this specifically needs to be done through VB, you could use MS Excel.
 
During research I have found the 'RADIX' sort, very fast and very stable.

Would recommend it to anyone sorting large files.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor