Built In Support for Sorting Objects
I have an upcoming project requiring that VBA objects be sorted.
I know that I can write the objects out to a Worksheet and then sort the objects and re-read them. But I'd prefer to keep everything in memory. ... Um I've googled and discovered functions for Quicksort and Bubblesort. I could use those. But, Does Excel provide any support for sorting objects. Like Java does with the Comparable class or like C does with Quicksort and a pointer to a function. ..... To give you an idea of what I'm working on, objects are first sorted on a double, then the objects are broken into a partition and sorted within the partition, then the partitions are sorted, and then partitions of the partitions are sorted. Thanks. |
Built In Support for Sorting Objects
Try something like this:
http://www.vbrad.com/pf.asp?p=source...collection.htm Or create a disconnected ADO recordset, populate its columns with your object properties and then sort that. Tim. wrote in message ups.com... I have an upcoming project requiring that VBA objects be sorted. I know that I can write the objects out to a Worksheet and then sort the objects and re-read them. But I'd prefer to keep everything in memory. .. Um I've googled and discovered functions for Quicksort and Bubblesort. I could use those. But, Does Excel provide any support for sorting objects. Like Java does with the Comparable class or like C does with Quicksort and a pointer to a function. .... To give you an idea of what I'm working on, objects are first sorted on a double, then the objects are broken into a partition and sorted within the partition, then the partitions are sorted, and then partitions of the partitions are sorted. Thanks. |
All times are GMT +1. The time now is 04:24 PM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com