Warning: file_get_contents(/data/phpspider/zhask/data//catemap/0/iphone/43.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Iphone 在\u reply\u to \u中,用户\u id始终作为null返回_Iphone_Ios_Objective C_Twitter - Fatal编程技术网

Iphone 在\u reply\u to \u中,用户\u id始终作为null返回

Iphone 在\u reply\u to \u中,用户\u id始终作为null返回,iphone,ios,objective-c,twitter,Iphone,Ios,Objective C,Twitter,大家好,我正试图通过我的应用程序回复一条特定的推文。代码如下: NSMutableDictionary *parameters = [[NSMutableDictionary alloc] init]; [parameters setObject:[[myAccount.currentTweet objectForKey:@"id"]stringValue] forKey:@"in_reply_to_status_id_str"]; SLRequest *request = [SLR

大家好,我正试图通过我的应用程序回复一条特定的推文。代码如下:

NSMutableDictionary *parameters = [[NSMutableDictionary alloc] init];
[parameters setObject:[[myAccount.currentTweet objectForKey:@"id"]stringValue]     
forKey:@"in_reply_to_status_id_str"];

SLRequest *request = [SLRequest requestForServiceType:SLServiceTypeTwitter   
requestMethod:SLRequestMethodPOST URL:[NSURL  
URLWithString:@"https://api.twitter.com/1.1/statuses/update.json"] 
parameters:parameters];`
以下是Twitter API JSON在成功发布回复时返回给我的内容

“id_str”=337918014110433281;“回复至屏幕名称”=地质IRPR;“在对状态的回复中,id=”;“在对状态的回复中”;“在答复用户id时”=1378947649;“在回复用户id时”=1378947649

正如您在回复中看到的,“in_reply_to_user_id”已填充,但有趣的是,“in_reply_to_status_id”仍为空。即使我传递了“in_reply_to_status_id”参数,我也包含了@username。还是不行


帮助ppppp

在第二行中尝试[parameters setValue:而不是setObject.

我相信这是因为我正在使用SLComposeViewController发布回复!!我无法在回复用户id中的
“之间建立连接”
在SLComposeViewController中。因此,每次都会生成一条新的tweet,在用户id的回复中没有