Hi you can use the peoplePickerNavigationController Delegate to do this
-(BOOL)peoplePickerNavigationController:
(ABPeoplePickerNavigationController *)peoplePicker
shouldContinueAfterSelectingPerson:(ABRecordRef)person
{
if(!ABRecordCopyValue(person,kABPersonEmailProperty) //Check if email field is empty
{
[peoplePicker dismissModalViewControllerAnimated:NO]; //dismiss the person with email field empty
}
return YES;
}
}
Dont forget to add delegate on your interface with tags in the .h file
ie,
#import <UIKit/UIKit.h>
#import <AddressBook/AddressBook.h>
#import <AddressBookUI/AddressBookUI.h>
@interface ViewController : UITableViewController<ABNewPersonViewControllerDelegate,ABPeoplePickerNavigationControllerDelegate,ABPersonViewControllerDelegate,UIAlertViewDelegate>