V4RB, syntax for sorting of sets.
Ruslan Zasukhin
sunshine at public.kherson.ua
Wed Oct 6 15:11:06 CDT 2004
On 10/6/04 2:38 PM, "Erik Mueller-Harder"
<valentina-list at vermontsoftworks.com> wrote:
> On Oct 5, 2004, at 17:11, Ruslan Zasukhin wrote:
>
>> dim order as array ?
>>
>> order(1) = new VSortPair( f1, kAsc )
>> order(2) = new VSortPair( f3, kDesc )
>> order(3) = new VSortPair( f2, kAsc )
>>
>> SortedSet = t.Sort( set, order )
>>
>>
>> Do you like such syntax?
>
> It's a little verbose, but it's certainly clear and orderly. I assume
> the first array element would be the primary sort. I'd be fine with it
> -- but then I used to write in COBOL. ;-)
>
>> It seems we have no other way for RB...
>
> Would this be impractical:
>
> SortedSet = t.Sort(set, f1, kAsc, f3, kDesc, f2, kAsc)
>
> or even:
>
> Set.Sort(f1, kAsc, f3, kDesc, f2, kAsc)
But how I can do this in RB plugin ?!
REALbasic do not allow functions with variable number of parameters.
--
Best regards,
Ruslan Zasukhin [ I feel the need...the need for speed ]
-------------------------------------------------------------
e-mail: ruslan at paradigmasoft.com
web: http://www.paradigmasoft.com
To subscribe to the Valentina mail list go to:
http://lists.macserve.net/mailman/listinfo/valentina
-------------------------------------------------------------
More information about the Valentina-beta
mailing list