In Android, is it possible to share files between 2 different apps running in separate processes?
+1
A:
Not the files within your apk. But you can always share files via the sdcard for example. Or if you move them to the data directory of your app but leave them in Context.MODE_WORLD_READABLE.
Mathias Lin
2010-08-02 01:38:50
Context.MODE_WORLD_READABLE sounds like exactly what I need. Thanks!
zer0stimulus
2010-08-04 00:55:52
+1
A:
In several different ways. The "duh" way would be to store the file on the /sdcard, which is essentially the Wild West as far as file permissions go, so any process can read any file.
If you want to go for extra credit, you can write a ContentProvider that serves data. It really depends on what your setup is - do you have loose files? Is there any downside to storing them on the sdcard (where they really belong anyway?)
EboMike
2010-08-02 01:39:08