title: Is this the right way to delete a contact from the iPhone?
body: <p>I am trying to delete a contact from the iPhone which I have created. I tried to find a good working example of deleting a contact, however didn't find one. Adding a contact seemed quite easy but deleting one seems hard. The following code does not work, but it seemed to be plausible: </p>
  
  <pre><code>ABAddressBookRef addressBook = ABAddressBookCreate();
  ABRecordRef delete = ABPersonCreate();
  
  ABRecordSetValue(delete, kABPersonFirstNameProperty, @"Max", nil);
  ABRecordSetValue(delete, kABPersonLastNameProperty, @"Mustermann", nil); 
  
  ABAddressBookRemoveRecord(addressBook, delete, &amp;error);
  ABAddressBookSave(addressBook, &amp;error);
  </code></pre>
  
  <p>Could anyone help me out.</p>
  
  <p>Thanks in advance for your help.</p>
  
  <p>Max</p>