我想将短信邀请发送到从联系人列表中选择的多个电话号码,我尝试使用ABPeoplePicker但是它没有正确显示,我的联系人列表总是显示为空白。
- (void)viewDidLoad
{
[super viewDidLoad];
UIBarButtonItem *addButton = [[UIBarButtonItem alloc] initWithBarButtonSystemItem:UIBarButtonSystemItemAdd target:self action:@selector(showAddressBook)];
self.navigationItem.rightBarButtonItem = addButton;
}
#pragma mark - Private method implementation
-(void)showAddressBook{
_addressBookController = [[ABPeoplePickerNavigationController alloc] init];
[_addressBookController setPeoplePickerDelegate:self];
[self presentViewController:_addressBookController animated:YES completion:nil];
}
我觉得我做错了什么,任何人都可以帮助我。