Questions tagged [abaddressbook]

The ABAddressBook opaque type provides a programming interface to the Address Book — a centralized database used by multiple applications to store personal information about people. Available on iOS 2.0 or above , and Mac OS X

The ABAddressBook opaque type (whose instances are known as address books) provides a programming interface to the Address Book—a centralized database used by multiple applications to store personal information about people. The Address Book database also supports the notion of a “group” containing one or more persons. People may belong to multiple groups, and groups may also belong to other groups.

The ABAddressBook opaque type provides functions for creating references to the Address Book database, saving changes, discarding changes, and registering for changes made externally (by other threads or processes) to the database.

812 questions
0
votes
1 answer

Swift extension for getting instance private property

I'm using this open source library which is a wrapper on AddressBook.framework. There's no method for deleting contact, so I'm gonna use default ABAddressBookRemoveRecord. However for that I need the ABAddressBookRef. Since it's declared in…
Adam Bardon
  • 3,829
  • 7
  • 38
  • 73
0
votes
1 answer

Get Contact Image Data using ABPersonCopyImageData

I'm trying to get the contact details out of the address book on the Mac. I can get the first name and last name fields etc, but I'm struggling with the syntax for ABPersonCopyImageData. Now according to the documentation ABPersonCopyImageData takes…
iphaaw
  • 6,764
  • 11
  • 58
  • 83
0
votes
2 answers

Unwrap ABMultiValueCopyLabelAtIndex

Currently I have a crash when reading phone No. with empty label: fatal error: unexpectedly found nil while unwrapping an Optional value if let phones: ABMultiValueRef = ABRecordCopyValue(person, kABPersonPhoneProperty)?.takeRetainedValue(){ …
Shmidt
  • 16,436
  • 18
  • 88
  • 136
0
votes
2 answers

Getting/Generating vCard (.vtf file) from Address Book ID

Im looking for a way to generate/get an electronic business card (vCard) from contacts using an Address Book ID. I have been able to do this using the users name using this code ABAddressBookRef ab = ABAddressBookCreateWithOptions(NULL,…
huddie96
  • 1,240
  • 2
  • 13
  • 26
0
votes
1 answer

Display contacts from Addressbook

I need to access the users addressbook and populate a tableview with profile image and the name of each user. I am getting a warning 'ABAddressBookCreate' is deprecated: first deprecated in iOS 6.0 and also no contacts are being displayed. My code…
Illep
  • 16,375
  • 46
  • 171
  • 302
0
votes
1 answer

EXC BAD ACCESS in ABRecordCopyValue

I get EXC_BAD_ACCESS problem either while getting birthday or email for random people variable. I tried using the following code which fails when I run it using dispatch_async. ABAddressBook addressBook = ABAddressBookCreateWithOptions(NULL,…
meteors
  • 1,747
  • 3
  • 20
  • 40
0
votes
1 answer

Get NSURL for image data of contact

I need to get the reference URL for the stored image of a contact. If I'm getting an image from a UIImagePickerController, I can get that simply by doing this. NSURL *imageURL = [info objectForKey:UIImagePickerControllerReferenceURL]; But how do I…
0
votes
1 answer

IOS AddressBook Contacts Null Issue on real device

I am getting contacts from addressBook and i tested it on simulator there is no first or second name null issue. But when I trying to test it on real device it give me first or second name Null issue on many rows. please help me my source code is -…
Janisar
  • 31
  • 5
0
votes
2 answers

Fetching all images from ABAddressBook crashes due to memory pressure

I'm querying all persons from the IOS address book and store their image in a local cache. Everything works fine for small address books - however a lot of entries (>1000) crash the app due to memory pressure. After investigating the issue it seems…
Simon Heinzle
  • 1,095
  • 1
  • 9
  • 17
0
votes
1 answer

Open Address Book and select a phone number of a contact which is having multiple numbers in iOS

I am developing a dialer application in XCode. In my application there is a button to pickup phone numbers from AddressBook. When a user click on that button I need to open the original iOS AddressBook and the user must be able to select a contact.…
SHOUKATHALI P
  • 35
  • 2
  • 10
0
votes
1 answer

ABAddressBook detect contact record changes

Is there a way to detect which contact records have changed ? I understand there are 2 options to detect change: kABDatabaseChangedNotification and kABDatabaseChangedExternallyNotification ABAddressBookRegisterExternalChangeCallback I would like…
user1046037
  • 16,755
  • 12
  • 92
  • 138
0
votes
0 answers

ABAddressBookSave not working in iOS 8

I am trying to add contact in device contact list. The code is working fine in iOS7 but not working in iOS8. I am getting "didAdd 0" in ios8 --- --- --- ABAddressBookAddRecord(iPhoneAddressBook, newPerson, nil); BOOL didAdd =…
Ranjitsingh Chandel
  • 1,479
  • 6
  • 19
  • 33
0
votes
1 answer

iOS AddressBook linked account Records do not show in sorted copy

using an iPhone 6 running iOS 8.2 I added a gmail account via the os settings, and the contacts (~350) for gmail show up in my contact list. I also added 3 new contacts directly via the phone. If I try to programtically retrieve all contacts via…
MattoTodd
  • 14,467
  • 16
  • 59
  • 76
0
votes
0 answers

Is it possible to programmatically disable an ABSource or ABGroup in the main Contacts app?

I'm building an alcohol prevention app and one of the features is to block the user's contacts for a given period of time so that they don't irresponsibly make drunken calls/texts to people. The current (and very old) version implements it by…
Matthew Quiros
  • 13,385
  • 12
  • 87
  • 132
0
votes
2 answers

iPhone Address Book - Actual Addresses

I'm trying to retrieve all the addresses from the address book and display them in a tableview, but I am having trouble understanding the structure of the dictionary for which street addresses are returned. Does anyone know of a tutorial or relevant…
Ben Harris
  • 5,664
  • 3
  • 30
  • 27