Sorting an array of objects

Hello,

i’ve made an array of objects like :
(code is resumed of course)


_tab[x] = new ObjectName(..parameters);
_tab[x].z = z;

and I’d like to sort it by it’s z property with the help of “sortOn”
but as it’s an array of objects the following syntax doesn’t work :


_tab.sortOn("z", Array.DESCENDING );

what is the correct syntax to touch the z property of my objects ?