我们如何从 PIMItem 获取字段标签。以下代码与 PIMList
String label = pimList.getAttributeLabel(
blackBerryContact.getAttributes(Contact.TEL, i));
但我有 PIMItem。在下面的代码中有一个PIMItem.getPIMList()
为我返回 null 的方法。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