-
Re: iCloud Drive Folder
Schindler Nov 2, 2015 8:09 AM (in response to Giordano)Good question. I just had to do this myself recently.
To see your app's folder in your iCloud Drive, you have to modify the Info.plist: Create an `NSUbiquitousContainers` dictionary. Within it, create a dictionary with the name of your ubiquity container. For example, `iCloud.com.yourcompany.yourapp`. Within it, create three keys: `NSUbiquitousContainerName`, a String, `NSUbiquitousContainerIsDocumentScopePublic`, a Boolean, and `NSUbiquitousContainerSupportedFolderLevels`, a String. The first of these three is the name of the folder. The second determines whether you will see your app's folder in iCloud Drive in, e.g., Finder on Mac. You'll want this value to be `YES`. The last determines whether the app's folder can have sub-folders. A value of `None` is accepted, meaning 'no,' but I don't recall the other accepted values.
N.B.: The changes to these keys will only take effect if your app's version increments; and incrementing the Build No. of your target is sufficient.
Also: The documentation suggests that only *used* containers appear 'publicly' in iCloud Drive, so a new empty container might not show up. I found this to be the case. When I saved a file to the `Documents` subdirectory of the ubiquitous container, only then did the app's directory appear in iCloud Drive.
R
-
Re: iCloud Drive Folder
rschluet Nov 23, 2015 8:07 AM (in response to Schindler)I have been working on this, too. I have added the keys, upped the version number, located the ubiquity container, and wrote a test file there. I can loop through the files in the ubiquity container in my app (OSX) and the test file is there. However, I cannot see it in the iCloud Drive in the finder.
-
Re: iCloud Drive Folder
rschluet Nov 23, 2015 8:18 AM (in response to Schindler)Additional information: On my Mac, I go to system settings, iCloud, iCloud Drive options. It lists apps that store docs there and my test app, iCloudTest, shows up there. (I wonder what the checkmarks do there)
However still, I don't see that folder in the finder for iCloud Drive.
-
Re: iCloud Drive Folder
Schindler Mar 28, 2016 10:24 AM (in response to rschluet)I read somewhere that in order to see the app's iCloud Drive in Finder, the app's ubiquity container must have a `Documents` subdirectory. And perhaps a non-empty `Documents` subdirectory, initially.
R
-
Re: iCloud Drive Folder
cameronchu Aug 10, 2017 12:38 AM (in response to Schindler)My iphone app can write a file under "AppName" folder in iCloud Drive, but not able to write to "Documents" folder in iCloud.
If I use Finder in my MacBook to look at files in my iCloud Drive, only "Documents' folder can be seen, not "AppName" folder.
However, in my iphone, both "Document" and "AppName" folder can be seen.
Why I can't see "AppName" folder created by my iphone app using MacBook?
Is there any way to write file directly to Documents folder in iCloud Drive?
-
-
-
Re: iCloud Drive Folder
jpcoates Sep 21, 2017 2:28 PM (in response to Schindler)Here is where it is explained.
https://developer.apple.com/library/content/qa/qa1893/_index.html
The funny thing is, at least what I am experiencing, is that the folder and a file in it appear when I use the new iOS 11 Files app when I search for my app and I can see them, however that does not work when I search or look for them using the iCloud app on my Mac or online. What am I missing? Updating the Bundle version did allow it to write the file at least. But it is still not visible using the iCloud app on my Mac or online.
-
Re: iCloud Drive Folder
hlx Jan 5, 2018 9:57 AM (in response to Schindler)I had the same experience with only "used" containers appear 'publicly' in iCloud Drive. Only way I was able to make my container folder showed up in iCloud Drive was to create a temporary file on launch of my app. Question now is how do I make the container "used" for a new user without having to create a file.
-
Re: iCloud Drive Folder
JoePasadena Nov 1, 2018 12:20 PM (in response to hlx)what do you mean by "used" containers appear 'publicly'?
I had this same problem, can't solve, my app write file to iphone, but can't be seen on iCloud.com or Mac
-
-
-
Re: iCloud Drive Folder
JoePasadena Nov 19, 2018 6:20 PM (in response to Giordano)Have you solved this issue? How?