嗨,我正在开发一个应用程序,当我单击联系人时,它会转到 ABpeoplePicekrNavigationcontroller 并以列表的形式在表格中显示所有联系人。但我想选择所有联系人以便我想执行一些操作。那么我该如何实现这个.
我不确定这是要问的正确问题。实际上,我正在尝试将联系信息发送到下一个屏幕,而不是每次我想选择整个联系人列表时都选择单个联系信息。那么我该怎么做呢?
我以为即使空间不适合单个单元格,我也会让它们显示在单个单元格中。只需向它们显示单个单元格,以便选择一个包含所有联系信息的单元格会更好地发送..
所以任何人都可以建议我选择所有联系人列表而不是选择一个联系人的正确方法。我不知道我们是否可以这样做?这是我用于访问联系人列表的以下代码。
- (IBAction)configureMyContact:(id)sender {
ABPeoplePickerNavigationController *peoplePicker = [[ABPeoplePickerNavigationController alloc] init];
peoplePicker.peoplePickerDelegate = self;
peoplePicker.navigationBar.topItem.title = NSLocalizedString(@"CHOOSE_CONTACT_TITLE", @"Defining my contact title.");
[self presentModalViewController:peoplePicker animated:YES];
[peoplePicker release];
}
- (void)peoplePickerNavigationControllerDidCancel:(ABPeoplePickerNavigationController *)peoplePicker {
[self dismissModalViewControllerAnimated:YES];
}
- (BOOL)peoplePickerNavigationController:(ABPeoplePickerNavigationController *)peoplePicker
shouldContinueAfterSelectingPerson:(ABRecordRef)person {
myContactID = ABRecordGetRecordID(person);
[self refreshMyContactButton];
[self saveMyContactID:myContactID];
[self dismissModalViewControllerAnimated:YES];
return NO;
}
- (BOOL)peoplePickerNavigationController:(ABPeoplePickerNavigationController *)peoplePicker
shouldContinueAfterSelectingPerson:(ABRecordRef)person
property:(ABPropertyID)property
identifier:(ABMultiValueIdentifier)identifier{
return NO;
}