Questions tagged [uidocumentbrowservc]

44 questions
2
votes
0 answers

Rename document using rename view Document Browser-Based App

Rather than implementing my own document rename method, I would like to use the document browser default view that can be reached by clicking the title of a file in a document browser. To do this I believe that one must call the rename method…
joshLor
  • 1,034
  • 1
  • 12
  • 27
2
votes
2 answers

Importing files in iOS : UIDocumentPicker vs UIDocumentBrowser

As per the documentation, both UIDocumentPickerViewController and UIDocumentBrowserViewController can be used for importing documents outside an apps sandbox. For selecting & importing a document from local document providers/cloud locations, which…
2
votes
3 answers

How to add back or cancel button to dismiss UIDocumentBrowser

I need to present UIDocumentBrowser for uploading a document. But I am not able to place a back or cancel button in the navigation bar. The image below is a screenshot of the file browser in WhatsApp. Can anybody help me?
Britto Thomas
  • 2,092
  • 1
  • 15
  • 28
2
votes
0 answers

Saving and loading UIDocumentBrowserViewController

I know I can encode/decode my files for saving/loading at my UIDocument from UIDocumentBrowserViewController using the code below, as explained on Apple's 2017 WWDC. class Document: UIDocument { override func contents(forType typeName: String)…
2
votes
2 answers

Cannot access/import contents of iCloud file picked in iOS 11 document browser

Besides opening and saving its own custom documents, my iOS 11 document browser-based app should be able to import an appropriately formatted text file and convert it into a document of its own. However, when picking a text file in the document…
emime
  • 65
  • 7
2
votes
1 answer

Pick UIDocument automatically in UIDocumentBrowserVC

I am using a uidocumentbrowservc and want to pick a UIDocument programmatically. In my case it is because i want to automatically load the last used UIDocument to save the user some time on launch, as my app seldom changes documents. My naive…
A. Vage
  • 35
  • 5
2
votes
1 answer

UIDocumentBrowserViewController bug with UTIs

I created an app for iOS 11 with an UIDocumentViewController (From the Xcode 9 template). I registered document types to support .swift files (public.swift-script) and it’s working with open in place and Files app, but in the app’s browser, files…
Emma Labbé
  • 667
  • 7
  • 18
1
vote
1 answer

open document programmatically from UserDefaults in UIDocumentBrowserViewController

I am working on a document based app in swift using UIDocumentBrowserViewController. I would like the app to default to opening the previous file that was used in the last session. When exiting the app I save the file URL in UserDefaults. When I…
siege097
  • 83
  • 7
1
vote
1 answer

How to reopen a UIDocument on iCloud using UIDocumentBrowserViewController

I've developed a document based iOS app using the UIDocumentBrowserViewController (its a game). On startup of the app I want to reopen the last used UIDocument automatically. For that I store the url string of the created or opened UIDocument in the…
FPP
  • 278
  • 3
  • 7
1
vote
2 answers

Prohibit exporting or sharing documents in UIDocumentBrowserViewController

Is there any way to prohibit exporting files in my UIDocumentBrowserViewController-based application that also provides a FileProvider? The user should only be allowed to view and edit files in the app. The user should be able to move files around…
heyfrank
  • 5,291
  • 3
  • 32
  • 46
1
vote
1 answer

Change UIDocumentBrowserViewController Create Document button text

I have a document based iOS app that uses UIDocumentBrowserViewController. The app allows document creation, so the file browser that appears when the app launches contains the standard button with the large + symbol and default text Create…
1
vote
1 answer

Document Renaming with UIDocumentBrowserViewController

I am using the "new way" of storing documents (iOS 11+) using UIDocumentBrowserViewController. No need for iCloud API, Entitlements etc. -- just works (under control of the separate Document Browser process). However, I haven't figured out how to…
habitoti
  • 229
  • 2
  • 15
1
vote
1 answer

Present an iCloud file without user picking it from the DocumentBrowser

I need to load an iCloud file when my app first starts up. I want the app to display the last opened file from when the app was closed, and so if the last opened file is an iCloud file, this is where I run into problems. First of all let me state…
Adam
  • 2,070
  • 1
  • 14
  • 18
1
vote
1 answer

How do I assign a template file's localized name?

My iOS application allows a user to begin by selecting a template document. For example, in Pages you could choose to start with the "Essay" template. That template document is copied and opened. I'm running into a localization issue and cannot find…
Serban
  • 11
  • 2
1
vote
1 answer

Present a view controller just before the UIDocumentBrowserViewController to be shown at launch

Here are the facts: I have a document based app using iOS 11's UIDocumentBrowserViewController. And as noted in the documentation, I set it as my root view controller: Always assign the document browser as your app's root view controller. Don't…
Zaphod
  • 6,758
  • 3
  • 40
  • 60