PDF 选择器——就像媒体选择器——有可能吗?
我使用 MPMediaPickerController 从用户的 iPod 库中选择媒体项目(音频录音)。我想做一些类似的事情,从用户的 iBooks 应用程序中选择 PDF 文件。 iBooks 中是否有类似于 MPMediaPickerController for PDF 的东西?
我查看了 SDK 框架列表并进行了一些 Google 搜索,但没有找到任何内容,但我仍然希望它存在......
I've used MPMediaPickerController to select media items (audio recordings) from the user's iPod library. I'd like to do something similar to select PDF files from the user's iBooks app. Is there anything similar to MPMediaPickerController for PDFs in iBooks?
I looked through the list of SDK frameworks and did some Google searches and didn't find anything, but I'm still hoping it exists...
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我应该更广泛地提出我的问题,因为我真的只是想让用户能够将 PDF 文件加载到设备上,然后从我的应用程序中选择它们。他们不必通过 iBooks,我只是认为这是将 PDF 导入应用程序的最简单方法。
不管怎样,我刚刚发现了 UIFileSharingEnabled 选项,它允许用户通过 iTunes 将文档直接复制到我的应用程序。将文件复制到设备上后,我的应用程序可以使用 NSFileManager (文档中有一些很好的代码示例)。这就是我现在正在做的事情,而且效果很好。
I should have asked my question more broadly, because I really just want to give the user the ability to load PDF files onto the device and then select them from within my app. They don't have to go through iBooks, I just thought that would be the easiest way to get PDFs onto the app.
Anyway, I just discovered the UIFileSharingEnabled option, which lets users copy documents directly to my application via iTunes. Once the files are copied onto the device, my app can find them using NSFileManager (the documentation has some good code samples). So that's what I'm doing now and it works great.