//       
private void BuildNameList() {
    //   
    nameList = new List("Address-Book", List.IMPLICIT);
    nameList.setCommandListener(this);
    //   
    nameList.addCommand(add);
    //    
    nameList.addCommand(ok);
    try {
        //   
        int size = recordStore.getNumRecords();
        //     ID 
        recIndexes = new int[size];
        //      
        AlphabeticalOrdering comparator = new AlphabeticalOrdering();
        //    
        RecordEnumeration re = recordStore.enumerateRecords
                               (null, comparator, false);
        //    ID 
        int i=0;
        //  ;     
        //     ID  ,
        //      ID  
        while(true) {
            //  ID  
            int id = re.nextRecordId();
            //  ID  
            recIndexes[i++]=id;
            //    ID
            byte[] record = recordStore.getRecord(id);
            //     
            ByteArrayInputStream bais = new ByteArrayInputStream(record);
            //  ,    
            DataInputStream dis = new DataInputStream(bais);
            //         
            nameList.append(dis.readUTF(),null);
        }
    }
    catch(RecordStoreException rse) {}
    catch(IOException ioe) {}
}
