Accessing iCloud image files in the Xojo iOS app

I am developing an iOS app and would like to access image files in iCloud and use them within the app.

Specifically,

  1. Save any image to iCloud Drive from your Mac.

  2. Run the developed app on an iPad signed in with the same Apple ID as the Mac.

  3. Access iCloud Drive within the app on the iPad and use the image file saved from the Mac within the app.

Currently, I am able to build the iOS app I am developing via Xcode and test play it on an actual iPad. However, the app I am testing does not have the essential iCloud function. This is because an error occurs if the iCloud function is included.

Could you help me access iCloud?

Are you also developing in Xojo?

Thank you for reply @Jeff_Tullin .

I have successfully tested the iOS app I am developing with Xojo on an actual iPad via Xcode. All development is done with Xojo.

Do you have the MBS plugins?

I use this code

Dim types() As String
types.append "image/jpeg"
types.append "image/png"
Dim asCopy As Boolean = True
picker = New UIPicker(UIPicker.ModeOpen, types, asCopy)
picker.Present

where picker is a UIDocumentPickerMBS

My DidPickDocuments event :

If me.documentPickerMode = ModeExportToService Then
//no good here
Else 
  For Each url As String In urls
    dim file as new FolderItem(url, FolderItem.PathModes.URL)
    //handle each file in turn
  //eg

//if file.name.Right(4) = ".png" or file.name.Right(4) = ".jpg" then
  //  var pic as picture
    //pic = picture.open(file)
 next
end if

Thank you @Jeff_Tullin .
I’ll go back home and try it right away.