Sort a Picklist

Sort a Picklist

I have a form with two lookup fields.  The fields are:

Client  - a lookup from form Clients;
Project - a lookup from form Projects.

On load I want to filter Client so that it contains only those clients that have a project and sort the resulting Client list.

I can filter correctly but not sort.

Code for On Add - On Load is as follows:

clientList  =  Projects  [(Client is not null)] sort by  Client ;
// alert(Projects.Client);
clear Client;
Client:ui.add(clientList.Client.getall());


Help appreciated.

Thanks!!