即時通訊使用facebook_skd_3.1(Xcode中的iOS 4.5)我通過調用 FBFriendPickerViewController,在單擊完成按鈕我曾試圖發佈消息
所選擇的朋友牆得到了好友列表,但我得到這個錯誤: - 警告:在演示或解散過程中嘗試從視圖控制器 中解僱!
2012年12月6日19:37:09.187 ........項目[5474:19a03]錯誤:HTTP狀態代碼:在警報視圖在朋友牆上發佈消息時的集成錯誤?
error =Error Domain=com.facebook.sdk code=5" ..........
message = "(#200)the user hasn't authorized the application to perform this action";
type = OAuthException
};
};
code=403;
com.acebook.sdk:HTTPStatuscode=403}
代碼403
錯誤: -
-(void)facebookViewControllerDoneWasPressed:(id)sender {
NSString* userid;
for (id<FBGraphUser> user in self.friendPickerController.selection)
{
NSLog(@"\nuser=%@\n", user);
userid = user.id;
}
NSMutableDictionary* dictaram = [[NSMutableDictionary alloc]
initWithObjectsAndKeys:@"like this!", @"message", nil];
[FBRequestConnection startWithGraphPath:[NSString stringWithFormat:@"%@/feed", userid]
parameters:params HTTPMethod:@"POST"
completionHandler:^(FBRequestConnection *connection, id result, NSError *error)
{
UIAlertView *alertView = [[UIAlertView alloc] initWithTitle:@"Shared"
message:[NSString stringWithFormat:@ %@! error=%@", fbUserName, error]
delegate:nil
cancelButtonTitle:@"OK"
otherButtonTitles:nil];
[alertView show];
}
];
[self dismissModalViewControllerAnimated:YES];
做我需要一些權限,或者有一些編碼錯誤,請幫助。
在此先感謝。
請顯示一些代碼 –
Facebook完全禁止,2013年初。現在不相關。 http://stackoverflow.com/questions/5665476/sending-a-private-message-to-your-friends-via-facebook-ios-sdk – Fattie