我使用了以下代码,Instagram应用程序显示我的照片,但文本我要分享的内容不显示。
我使用了注释属性,但它不起作用。我不知道哪里出错了?
instagram版本:3.5.0
我的iphone版本:5.0.1
xcode版本:4.6
问候。
NSURL *instagramURL = [NSURL URLWithString:@"instagram://app"];
if ([[UIApplication sharedApplication] canOpenURL:instagramURL])
{
NSString *jpgPath = [NSHomeDirectory() stringByAppendingPathComponent:@"Documents/image.igo"];
NSString *urlString = [[NSString alloc] initWithFormat:@"file://%@", jpgPath];
NSURL *imageUrl = [[NSURL alloc] initWithString: urlString];
self.docController = [self setupControllerWithURL:imageUrl usingDelegate:self];
self.docController.UTI = @"com.instagram.exclusivegram";
self.docController.annotation = [NSDictionary dictionaryWithObject:@"I want to share this text" forKey:@"InstagramCaption"];
[self.docController presentOpenInMenuFromRect: self.view.frame inView: self.view animated: YES ];
}
答案 0 :(得分:0)
根据Instagram论坛,第三方标题在最新的(3.5)版本中破裂。
https://groups.google.com/d/topic/instagram-api-developers/wLfX0cJUUyM/discussion
请参阅Mike Krieger的以下评论,承认错误:
https://groups.google.com/d/msg/instagram-api-developers/wLfX0cJUUyM/SK_m4IJ3wn8J