Sortwith question

If I have a two dimensional array and want to sort the rows on a specific column, how might I use the sortwith method to achieve this?

As sortwith works only on 1D arrays, you might build a new 1D array from your 2D one, concatenating the values with the desired ‘column’ in front, a separator of some kind ( comma? ), and the second value. Do the sortwith, then unpack the 1D array into your 2D one.

Any time I’ve been tempted to use a 2 dimensional array, I’ve gone with an array of class objects instead.

I just wish that a weblistbox cell was a class…

Do you use the data directly out of the WebListBox?

Managing the data separate from the Listbox would be really beneficial in this case, you would be able to sort and manage your data faster and easier. Only load it into the WebListBox once you have it in the order you want it.

I would try to keep working data out of the interface as much as you can with Web projects because of all the back and forth transfer.

The idea was to subclass weblistbox such that it had a sort capability.
The cell contents are one thing, but then there are other attributes and tags that go along with each cell and row and I wanted to preserve those. Hence the wish for a Row Class and Cell Class.

I see your point though when you reload the weblistbox you would reset those properties, but it seems to me one looses the re-usability of the subclass feature that way.