nagaradderKantesh
nagaradderKantesh

Reputation: 1690

Does Android support cross application file access

Does android support cross application file access i mean Lets say Application A created a file called "abcd.txt", can we access the file "abcd.txt" from another application B like how it can be possible in windows and not possible in iOS. please help.

Upvotes: 1

Views: 162

Answers (1)

MrSnowflake
MrSnowflake

Reputation: 4742

This is possible, even multiple manners.

If both applications are from the same developer they could use the same shared user id. This is an attribute in the AndroidManifest.xml, android:sharedUserId. When different applications/apks have the same userid they are able to read each others files. When using this technique, files are still prive to the rest of the OS, but are readable/writable by other apks from the same developer.

Another posibility is using the sdcard to share data. That storage is publicly available.

Android has built-in support for sharing data with other applications through the use of ContentResolvers. This does not work for files, but is probably the preferred way to shared data between applications.

Upvotes: 4

Related Questions