Hi Greg,

> Hi everyone,
> 
> How do I sort a subset of lines in a a field?  I've tried the
> handler below, but it gives an error.
> 
> on mouseUp
>  set the itemDelimiter to tab
>  sort lines 2 to 5 of fld "merged results" by item 3 of each
> end mouseUp

I think that you cannot sort some lines of a field at all.

Spontaneous thought ;-) :
Try to put the desired lines into a variable, sort that variable
and replace these lines with the variable.

Noone will ever tell the difference :-)

> Regards,
> 
> Greg
> 
Hope that helps...

Regards

Klaus Major

P.S. Of course i couldn't let this mail go out unconfirmed ;-)

This works (just tested):

on mouseUp
    put line 2 to 5 of fld 1 into things_to_sort
     sort lines of things_to_sort by word 2 of each
   put things_to_sort into line 2 to 5 of fld 1
end mouseUp

Luv' MC :-D


Archives: http://www.mail-archive.com/[email protected]/
Info: http://www.xworlds.com/metacard/mailinglist.htm
Please send bug reports to <[EMAIL PROTECTED]>, not this list.

Reply via email to