刪除多個聯繫人是這樣的,我通過數組CFArrayRef
然後刪除聯繫人,但代碼是不工作:我的代碼如何從通訊錄
CFArrayRef arrayRef = (__bridge CFArrayRef)multipleSeleted;
ABAddressBookRef addressbook = ABAddressBookCreate();
if (arrayRef != NULL) {
int count = CFArrayGetCount(arrayRef);
for (int i = 0; i < count; ++i){
ABRecordRef contact = CFArrayGetValueAtIndex(arrayRef, i);
ABAddressBookRemoveRecord(addressbook, contact, nil);
}
}
您想從設備聯繫人中刪除聯繫人嗎?還是從陣列? – Janmenjaya
從設備上刪除 – iOS
[我如何從主AddressBook中刪除聯繫人,當我刪除objective-c中的特定組時?](http://stackoverflow.com/questions/35569682/how-can-i-delete-當我刪除特定組中的代碼時 – Lion