sorting table fields

Bernard Devlin revolution at knowledgeworks.plus.com
Wed Dec 20 07:11:14 EST 2006


You can certainly do multi-column sorts by using a custom function  
applied to the sort line:

on mouseUp
   sort lines of field "table field" by mySortKey(each)
end mouseUp

function mySortKey pLine  --sorts by conjoining 2nd & 3rd columns of  
a multicolumn table
   set the itemDel to tab
   return  item 2 of pLine && item 3 of pLine
end mySortKey

That might or might not be the kind of thing you want to do.  I think  
there are probably much more sophisticated things to do within such a  
custom function.

"wednesday's greetings" to one and all

Bernard



More information about the use-livecode mailing list