我在尝试从 iCloud 导入时遇到应用文件夹被禁用的问题,请参见下图:
我检查了谷歌驱动器的 iCloud 导入,它没有被禁用,如下图所示:
我需要从其他应用的文件夹中获取文档,我做错了什么?
这是我在 info.plist 中的当前设置:
代码:
UIDocumentPickerViewController *documentPicker = [[UIDocumentPickerViewController alloc] initWithDocumentTypes[@"public.item"]
inMode:UIDocumentPickerModeImport];
documentPicker.delegate = self;
documentPicker.modalPresentationStyle = UIModalPresentationFormSheet;
[self presentViewController:documentPicker animated:YES completion:nil];
你需要在 UIDocumentPickerViewController 中添加 Utils
UIDocumentPickerViewController *picker=[[UIDocumentPickerViewController alloc]
initWithDocumentTypes: @[(__bridge NSString *) kUTTypeContent,
(__bridge NSString *) kUTTypeData,
(__bridge NSString *) kUTTypePackage,
(__bridge NSString *) kUTTypeDiskImage,
@"com.apple.iwork.pages.pages",
@"com.apple.iwork.numbers.numbers",
@"com.apple.iwork.keynote.key"] inMode:UIDocumentPickerModeImport];
关于ios - iCloud 文档选择器 : App folders are disabled on import,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/34306818/
欢迎光临 OGeek|极客世界-中国程序员成长平台 (http://jike.in/) | Powered by Discuz! X3.4 |