I/O Dialogs for IOS

Are there I/O Dialogs for IOS to Open files in the Documents folder?
Say I downloaded a file from the web which goes to the Documents folder on my iPad and I want my App to browse and load it, is this possible or do you always need to know the file name?

From the response I assume that there are none or not meant to be any. So if I have a Quiz App which has built in question bank but want the teacher to be able to develop their own questions and distribute them to the class, how would I achieve this if the student can’t browse to load that set of questions?

This situation makes me scream in frustration every time I try to look at iPad apps.
The SharingPanel presents a dialog that allows you to SEND text documents to mail , clipboard and iCloud.
But nothing similar to browse documents or iCloud.
MBS has iCloud declares but they are completely incomprehensible to me.

The answer to your question follows.

And I can tell you from experience that even though this is Apple’s guide and ‘normal method’, actual end users hate it with a passion and can rarely understand how to do it…

1/ Add Shared Documents entitlement to your App
2/ When you do that, the Documents folder for YOUR app will be exposed to a connected machine
3/ On an old Mac or current Windows, the user must open iTunes, find their device, open ‘Apps’, find your App, open the documents folder, and drag files into it.
3a/ On newer Macs, connect your iPad (preferably using a USB cable), on which the iPad will appear like an external drive, but you still have to find your App, and its documents folder, and copy files there.
4/ You dont get a file browser dialog in your Xojo app: you need to fake one by iterating through the contents of Specialfolder.documents and presenting a list to the user.

Its stuff like this that makes a mockery (to me) of calling the iPad a ‘computer’.

teacher to be able to develop their own questions and distribute them
You can use a sharingpanel to get a text file OUT of the machine by email.

USB cable - not all USB cables allows data transfer. So plugging it in doesn’t always ‘connect’. Users don’t like to hear they bought a cheap cable.
iCloud: I am desperate for Xojo to add Specialfolder.iCloud , or at least to find a simple example of using MBS.
Documents: you dont seem to be able to get at ‘the’ documents folder of the iPad unless it eludes me. Just the documents of your specific app.

I suspect what you’re looking for is this:


Is that a private case?
Cant see it in feedback…

Yeah, because it was created during test cycle of 2020r2. I ask for make it public.

Implement MobileSharingPanel.ShareFile
For now we can share Picture, Text and URL. Would be also helpful and important to add a new ShareFile Method to MobileSharingPanel to share a FolderItem.

I think @Christian_Schmitz might be able to provide this for iOS quite quickly, as it seems to have been present in the Filemaker libraries for some time:

Do you know if your target school uses Apple School Manager? If so, you might want to consider using ClassKit as this capability may be already built in.

I figure the teacher could email a link or even set up a link on their school’s intranet that the students navigate to and download so there are probably a few options for distributing. It’s really the student navigating to load it is my main issue.

Hi Greg, I can’t count on Schools in Australia using ASM.

Ok, well I did a proof-of-concept here today (because I was curious) and managed to mostly get a file browser working with a ton of declares. Just need to figure out why it doesn’t dismiss and why selecting a file isn’t working correctly.


Hi @Greg_O_Lone, Happy New Year, that would be an awesome addition :slight_smile: thanks Martin

I think I had this mostly working but ran into issues with background threads being used for part of it. There are two keys you need to add to the info.plist if you missed them:

UIFileSharingEnabled = true
LSSupportsOpeningDocumentsInPlace = true

For the view disappearing you have to do that manually I think. Here are two examples of how I handled something similar to that in iOSKit:

Hi @Jason_King and @Greg_O_Lone would this be a possibility for the next Xojo release or IOSKit?

1 Like

Since I just answered this differently on another thread:

This is instructions for making an iOS open certain file types.

1 Like