Thread: sortsub()
View Single Post
  #1  
Old 06-27-2009, 11:23 PM
DustyPorViva DustyPorViva is offline
Will work for food. Maybe
DustyPorViva's Avatar
Join Date: Sep 2003
Location: Maryland, USA
Posts: 9,589
DustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond repute
Send a message via AIM to DustyPorViva Send a message via MSN to DustyPorViva
sortsub()

.sortsubascending(index)
.sortsubdescending(index)

Will sort an array from the index provided in the subarrays.

Example:
this.test = {{"one",1},{"five",5},{"three",3},{"four",4},{"two ",2}};

this.test.sortsubascending(1);


Will return:
this.test = {{"one",1},{"two",2},{"three",3},{"four",4},{"five ",5}};

I'm not exactly sure of the syntax, but I'd like to see some way for this to be easily done.
Reply With Quote