Android.Content.Intent.ActionCreateDocument Field
Activity Action: Allow the user to create a new document.

Syntax

[Android.Runtime.Register("ACTION_CREATE_DOCUMENT")]
public const string ActionCreateDocument

See Also

Android.Provider.DocumentsContract
Intent.ActionOpenDocument
Intent.ActionOpenDocumentTree

Remarks

Activity Action: Allow the user to create a new document. When invoked, the system will display the various Android.Provider.DocumentsProvider instances installed on the device, letting the user navigate through them. The returned document may be a newly created document with no content, or it may be an existing document with the requested MIME type.

Each document is represented as a content:// URI backed by a Android.Provider.DocumentsProvider, which can be opened as a stream with ContentResolver.OpenFileDescriptor(Android.Net.Uri, System.String), or queried for NoType:android/provider/DocumentsContract$Document;Href=../../../reference/android/provider/DocumentsContract.Document.html metadata.

Callers must indicate the concrete MIME type of the document being created by setting Intent.SetType(string). This MIME type cannot be changed after the document is created.

Callers can provide an initial display name through Intent.ExtraTitle, but the user may change this value before creating the file.

Callers must include Intent.CategoryOpenable in the Intent so that returned URIs can be opened with ContentResolver.OpenFileDescriptor(Android.Net.Uri, System.String).

Output: The URI of the item that was created. This must be a content:// URI so that any receiver can access it.

[Android Documentation]

Requirements

Namespace: Android.Content
Assembly: Mono.Android (in Mono.Android.dll)
Assembly Versions: 0.0.0.0
Since: Added in API level 1