facebook sdk 4.17 iOS发送礼物与FBSDKGameRequestContent

时间:2016-11-21 10:26:01

标签: ios objective-c facebook facebook-ios-sdk facebook-ios-sdk-4.0

您好我在iOS应用中使用Facebook sdk 4.17。

我正在尝试使用FBSDKGameRequestContent发送礼物,当我从相同的代码发送时,我收到了2个不同的错误和2个不同的礼物:

FBSDKGameRequestContent *gameRequestContent = [[FBSDKGameRequestContent alloc] init];

gameRequestContent.message = @"Your gift is waiting for you";
gameRequestContent.title = @"Choose Friends";
gameRequestContent.recipients = recipentsToSend;
gameRequestContent.objectID = collection_item;
gameRequestContent.actionType = FBSDKGameRequestActionTypeSend ;

// Assuming self implements <FBSDKGameRequestDialogDelegate>
FBSDKGameRequestDialog* dialog = [[FBSDKGameRequestDialog alloc] init];
dialog.content = gameRequestContent;
dialog.delegate = self;
[dialog show];

礼物1错误1:

  

错误Domain = com.facebook.sdk.share Code = 2&#34;(null)&#34; UserInfo = {com.facebook.sdk:FBSDKErrorDeveloperMessageKey =当actionType为send或askfor时,objectID是必需的.com.facebook.sdk:FBSDKErrorArgumentNameKey = objectID}

礼物2错误2:

  

错误Domain = com.facebook.sdk.share Code = 100&#34;(null)&#34; UserInfo = {com.facebook.sdk:FBSDKErrorDeveloperMessageKey =参数object_id:无效的id:&#34; ChristmasHomeOrnament&#34;}

有人有任何想法吗?

0 个答案:

没有答案