나는 페이스 북 그래프 API를 사용하여 도움을 받아 사용자 친구 목록을 얻었습니다. JSON 형식입니다. 앞서 프로젝트에서 json 클래스를 가져 오기 전에 다음 메소드를 사용했습니다. 그러나 그것은 내가 정확히 여기서 내가 놓친 것을 이해하지 못하는 오류를 던진다.구문 분석 json 오류
내 코드 :
-(void)getuserfriends
{
NSDictionary *dict = [[NSDictionary alloc]initWithObjectsAndKeys:@"name,last_name,first_name",@"fields", nil];
FbGraphResponse *fb_graph_response = [fbGraph doGraphGet:@"me/friends" withGetVars:dict];
NSLog(@"getMeFriendsButtonPressed: %@",fb_graph_response.htmlResponse);
//htmlresponse is string
NSMutableDictionary *newdict = [fb_graph_response.htmlResponse JSONValue];
}
오류 : 는 선택과 방법을 선언하지 않는 인스턴스 메시지의 종류는 NSString 수신 'JSONValue'
문제가 해결되면 대답을 확인해야합니다 ... – TheRonin