PIMItem からフィールド ラベルを取得するにはどうすればよいですか。次のコードは PIMList を使用したものです
String label = pimList.getAttributeLabel(
blackBerryContact.getAttributes(Contact.TEL, i));
しかし、私は PIMItem を持っています。以下のコードには、null を返すメソッドがPIMItem.getPIMList()
あります。http://www.blackberry.com/developers/docs/5.0.0api/index.htmlの API には、「getPIMList()
Gets the PIMList associated with this item.
」と書かれています。以下は、私が達成しようとしているサンプル コードです。
// Load the address Book and allow the user to select a contact
BlackBerryContactList contactList = (BlackBerryContactList)
PIM.getInstance().openPIMList(PIM.CONTACT_LIST,PIM.READ_ONLY);
PIMItem userSelectedContact = contactList.choose();
// Now get the Field labels for contact numbers for userSelectedContact