user3300758 user3300758 - 1 year ago 188
Objective-C Question

ABAddressBookCreate deprecated

I'm creating an application that will save a contact to the address book, but when I use ABAddressBookCreate to my code, it appear as a warning. I'm coding in iOS 7.

My question is, what is the substitute for ABAddressBookCreate in iOS 7.

Any help will be appreciated. Thanks.

Answer Source

Use ABAddressBookCreateWithOptions() instead.

ABAddressBookRef addressBook = ABAddressBookCreateWithOptions(NULL, NULL);

More info on usage in the documentation here


The AddressBook framework is deprecated in iOS 9 and replaced with the new and improved Contacts framework:

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download