【问题标题】:"Error Domain Code=324" while upload photo using Facebook method使用 Facebook 方法上传照片时出现“错误域代码 = 324”
【发布时间】:2011-03-24 19:50:42
【问题描述】:

我正在使用带有 iPhone-SDK 的 Facebook 方法 API。授权后,我尝试上传图片,使用以下代码:

NSString *link = @"http://www.google.com/logos/2011/houdini11-hp.jpg";  
    NSURL *url1 = [NSURL URLWithString:link];  
    NSData *data1 = [NSData dataWithContentsOfURL:url1];  
    UIImage *img1  = [[UIImage alloc] initWithData:data1];  
    NSMutableDictionary *photos = [NSMutableDictionary dictionaryWithObjectsAndKeys:  
                                img1, @"picture",   
                                  nil];    
    [facebook requestWithMethodName:@"photos.upload"  
                  andParams:photos  
              andHttpMethod:@"POST"  
                andDelegate:self];

我收到了这个错误:

错误 DOMAIN = 操作无法完成。 (facebookErrDomain 错误 324。)

提前致谢。

【问题讨论】:

  • 你是否尝试使用 NSString *link = @"google.com/logos/2011/houdini11-hp.jpg"; NSMutableDictionary *photos = [NSMutableDictionary dictionaryWithObjectsAndKeys: @"image", @"type", link, @"src" nil]; [facebook requestWithMethodName:@"photos.upload" andParams:photos andHttpMethod:@"POST" andDelegate:self];
  • 没有。我认为我们不能以这种方式提供链接。

标签: ios facebook facebook-ios-sdk


【解决方案1】:

你可以在这里看到所有的错误代码..

http://www.takwing.idv.hk/tech/fb_dev/faq/general/gen_10.html

所以错误是缺少或无效的图像文件

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2014-07-09
    • 1970-01-01
    • 2011-10-13
    • 2021-08-29
    • 1970-01-01
    • 2011-03-13
    • 2013-06-28
    • 1970-01-01
    相关资源
    最近更新 更多