【发布时间】:2012-09-03 08:44:09
【问题描述】:
我已经搜索了几个通过 UIPasteboard 提出的帖子/问题,这些帖子/问题发布在 StackOverflow 上,但我没有找到任何解决问题的方法,所以发布了这个问题。
我想将复制的图像粘贴到 Twitter 的 NewTwitt 和 Facebook 的评论中,但即使粘贴板对象中有图像,我也没有获得粘贴选项。 我在 EMAIL 中获得了粘贴选项,它也可以正常工作。
这是我正在使用的代码:
//image is object of UIImage, which holds .png Image
UIPasteboard *objPasteboard = [UIPasteboard generalPasteboard];
NSData *imageData = [NSData dataWithData:UIImagePNGRepresentation(image)];
[objPasteboard setData:imageData forPasteboardType:@"public.png"];
我是否需要实现更多内容才能将其粘贴到 Twitter 和 facebook 中。我正在发布图像屏幕截图以供参考。
谁能帮帮我。
【问题讨论】:
标签: iphone objective-c ios5 uikit uipasteboard