2
我工作的項目,我需要邀請Facebook的朋友,但通知不發送在Facebook帳戶。IOS Facebook的朋友邀請不在Facebook的工作sdk
NSString *frindId=[[self.checkitem1 objectAtIndex:indexPath.row]valueForKey:@"id"];
NSMutableDictionary* params = [NSMutableDictionary dictionaryWithObjectsAndKeys:
@"Come check out my app.", @"message",
frindId, @"to",
nil];
[FBWebDialogs presentRequestsDialogModallyWithSession:nil message:[NSString stringWithFormat:@"Come check out my app."]
title:@"MyWorkOut"
parameters:params
handler:^(FBWebDialogResult result, NSURL *resultURL, NSError *error) {
if (error) {
// Case A: Error launching the dialog or sending request.
NSLog(@"Error sending request.");
} else {
if (result == FBWebDialogResultDialogNotCompleted) {
// Case B: User clicked the "x" icon
NSLog(@"User canceled request.");
} else {
NSLog(@"Request Sent.");
}
}
}
];
我已經完成上面的代碼邀請朋友使用Facebook的SDK。是他們邀請使用Facebook的朋友的任何解決方案sdk
月該鏈接幫助你 - http://stackoverflow.com/questions/30251540/fbfriendpickerdelegate-disappeared-with-facebook-v4/30252347#30252347 –
@VijayMasiwal此鏈接列出朋友。但我想邀請朋友 –
根據FBSDK文檔** invitable_friends API僅適用於具有Facebook Canvas應用程序實現的遊戲。此API僅適用於Graph API的2.0版(或更高版本)。** –