I'm guessing the objects in your vector are really some type that you made up with those fields. Going from there ... your comparator probably looks like:
Is that close? It needs some checks for nulls, instance of and such at the beginning to be very safe.
So now you want to sort by two or three fields. I do something like this:
Does that make sense? If the 1st field doesn't match I'm done. But if it does match I check the 2nd field. And if those match I check the 3rd field.
Note that I reversed myTwo and myOne in the 3rd
test to sort descending order on that field.
Does that look useful?
[ December 07, 2004: Message edited by: Stan James ]