iOS Developer Library

Developer

Address Book UI Framework Reference for iOS ABNewPersonViewControllerDelegate Protocol Reference

Options
Deployment Target:

On This Page
Language:

ABNewPersonViewControllerDelegate

The ABNewPersonViewControllerDelegate protocol declares the interface that ABNewPersonViewController delegates must implement.

  • Sent when the user taps Save or Cancel. If the user tapped Save, the current address book has been saved to the Address Book database.

    Declaration

    Swift

    func newPersonViewController(_ newPersonView: ABNewPersonViewController, didCompleteWithNewPerson person: ABRecord?)

    Objective-C

    - (void)newPersonViewController:(ABNewPersonViewController *)newPersonViewController didCompleteWithNewPerson:(ABRecordRef)person

    Parameters

    newPersonViewController

    The new-person-view controller that manages the new-person interface.

    person

    On Save, the newly created (and saved) person record.

    On Cancel, NULL.

    Discussion

    If the user tapped Save, pending changes in the current address book (ABAddressBook) have been saved by the time this message is sent to the receiver.

    The receiver must dismiss newPersonViewController.

    Availability

    Available in iOS 2.0 and later.