iOS Developer Library

Developer

AddressBookUI Framework Reference ABNewPersonViewControllerDelegate Protocol Reference

Options
Deployment Target:

On This Page
Language:

ABNewPersonViewControllerDelegate

Inheritance


Not Applicable

Conforms To


Import Statement


Swift

import AddressBookUI

Objective-C

@import AddressBookUI;

Availability


Available in iOS 2.0 and later.

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. (required)

    Declaration

    Swift

    func newPersonViewController(_ newPersonViewController: 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.

    Import Statement

    Objective-C

    @import AddressBookUI;

    Swift

    import AddressBookUI

    Availability

    Available in iOS 2.0 and later.