0
我想實現以前的答案。這裏建議代碼:將圖片添加到Facebook牆
-(void) postImageToFB:(UIImage *) image
{
NSData* imageData = UIImageJPEGRepresentation(image, 90);
Facebook* fb = [(uploadPicAppDelegate *)[[UIApplication sharedApplication] delegate] facebook ];
NSMutableDictionary * params = [NSMutableDictionary dictionaryWithObjectsAndKeys:[fb accessToken],@"access_token",
@"message text", @"message",
imageData, @"source",
nil];
[fb requestWithGraphPath:@"me/photos"
andParams:params
andHttpMethod:@"POST"
andDelegate:self];
}
但我越來越對長期未發現的錯誤:uploadPicAppDelegate
在Facebook的SDK或搜索網絡的我找不到這個(比其他附加類似的代碼)。這是一個自定義創建的數據類型 - 或者 - 我錯過了一個需要導入的文件?
謝謝。