java – Add ContactList on Blackberry – Education Career Blog

I want retrieve contacts from the address book on a BlackBerry. I can get the contacts using the following code:

AddressBookArguments abArg = new AddressBookArguments();
Invoke.invokeApplication(Invoke.APP_TYPE_ADDRESSBOOK, abArg);  

However I cannot access the selected contact in my application. How can I display the selected contact in my application?


try this code

BlackBerryContactList list = (BlackBerryContactList) PIM.getInstance().
                             openPIMList(PIM.CONTACT_LIST, PIM.READ_WRITE);
BlackBerryContact contact = (BlackBerryContact) list.choose();

Leave a Comment