I know that databases are stored inside the applications data folder how can i access the database from a separate application? Is there a way i can use a database in two separate apk's ?
3 Answers
If you define a Content Provider in your application then it can be accessed by other applications.
3 Comments
opc0de
Where i can find an example ?
Alexander
There are lots of examples on the net. You may want to check this overview from Google first developer.android.com/guide/topics/providers/…
user
@opc0de The
ContentProvider is the way to go if you want to access data from another application(that application will have to provide a ContentProvider). Besides the official tutorial that Alex provided, there is a simple app in the android samples that you should check out developer.android.com/resources/samples/NotePad/index.html .