Instance Method

documentBrowser:didImportDocumentAtURL:toDestinationURL:

Tells the delegate that a document has been successfully imported.

Declaration

- (void)documentBrowser:(UIDocumentBrowserViewController *)controller didImportDocumentAtURL:(NSURL *)sourceURL toDestinationURL:(NSURL *)destinationURL;

Parameters

controller

The document browser that performed the import action.

sourceURL

The document's original URL.

destinationURL

The document's URL after the import.

Discussion

To open the document as soon as it's imported:

  1. Open a new UIDocument subclass for the document (or use a file presenter and file coordination to access the document).

  2. Create a view controller to display the document.

  3. Present that view controller modally.

See Also

Creating New Documents

- documentBrowser:didRequestDocumentCreationWithHandler:

Asks the delegate to create a new document.

UIDocumentBrowserImportMode

The document browser's import modes.

- documentBrowser:failedToImportDocumentAtURL:error:

Tells the delegate that the document browser failed to import the specified document.