views:

15

answers:

1

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?

+1  A: 

try this code

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