How can we store and access a list of ABRecordRef
so that we can use this in another class and later on?
You can get recordId
from the record of type ABRecordRef
from
addressBook Then convert it into NSString
. Store it in NSUserDefaults
When you want to fetch the record...
fetch that recordId
from NSUserDefaults
,Convert it in integer
then use
ABRecordRef myRecord =
ABAddressBookGetPersonWithRecordID(addressBook, recordId);
So you will get the record which you saved earlier.