在我的tableView numberOfRowsInSection被称为两次,但不是的cellForRowAtIndexPath叫? 我想在的tableView显示Facebook好友列表(如果的cellForRowAtIndexPath叫我的问题解决)。
我在阵列得到正确的价值在这里,但如果所谓的表的方法,因为好友列表的解析不能完成它不是去的cellForRowAtIndexPath但下一次,当我重新载入数据首次显示值194(我在facebood的朋友)在numberOfRowsInSection但仍不去的cellForRowAtIndexPath。 我很厌倦了这个问题?
@implement RootViewController
//In this view i do two things. First use FBFeedPost to Fetch the Friend List from Facebook and Second navigate to FBFriends view
FBFeedPost *post = [[FBFeedPost alloc]initWithFriendList:self.imageView.image];
[post publishPostWithDelegate:self];
FBFriends *friendList=[[FBFriends alloc]initWithNibName:@"FBFriends" bundle:[NSBundle mainBundle]];
[[self navigationController] pushViewController:friendList animated:YES];
@end
@implement FBFeedPost
//After parsing friends list i pass Array to a FBFriend class function
FBFriends *obj1=[[FBFriends alloc]init];
[obj1 getFreindName:nameItems];
@end
@implement FBFriends
-(void)getFreindName:(NSMutableArray *)friendName
{
friendsArray=friendName;
NSLog(@"the count of name is %d",[friendsArray count]);// here i get right answer.
[self.tableView reloadData];
}
@end