Logo Icon Logo
A Crowd-sourced Cookbook on Writing Great Android® Apps
GitHub logo Twitter logo OReilly Book Cover Art

Sharing Files with a FileProvider

In Chapter: Data Persistence
Author: Ian Darwin ('idarwin')
Published? true
FormatLanguage: WikiFormat


You want to share internal-storage files (see <<r5028>>) with another app, without the bother of putting the data into a Cursor and creating a ContentProvider.


The ++FileProvider++ class allows you to make files available to another application, usually in response to an ++Intent++. It is simpler to set up than a Content Provider (<<r1558>>), but is actually a subclass of ++ContentProvider++.


To follow