How to get name and phonenumber peoplePicker

207 Views Asked by At

So i am trying to follow the guides and tutorials that apple gives about the ABPeoplePickerNavigationController.

So far what i have been able to do is to get the picker to show and see all the avaliable contacts using this code:

- (IBAction)showPicker:(id)sender
{
    ABPeoplePickerNavigationController *picker =
        [[ABPeoplePickerNavigationController alloc] init];
    picker.peoplePickerDelegate = self;

[self presentModalViewController:picker animated:YES];
}

And then to display the information i use the code provided by apple: https://developer.apple.com/library/ios/documentation/ContactData/Conceptual/AddressBookProgrammingGuideforiPhone/Chapters/QuickStart.html

If you scroll down a bit and see Listing 1-4 Displaying a person’s information.

Im using that code but it never runs.

All i can do is get the picker working. Select a person and see its information.

What i want to do is. After a person is clicked then ONLY the number/s will show and i will be able to click it to use it in code. How can i do this?

I am using my cellphone to post this question so please be gentle :P.

0

There are 0 best solutions below