Can apps share files?

I’m designing an app where due to the user interface, it would be a better app if it were two apps that shared a database and possibly an entire folder of art assets. Is there a good way to do this with Corona SDK?

I was looking at this:

http://developer.android.com/training/secure-file-sharing/setup-sharing.html

and this:https://developer.apple.com/library/prerelease/ios/documentation/General/Conceptual/ExtensibilityPG/FileProvider.html

Based on these articles, what I’m considering can work, but I’m wondering if it will work with Corona SDK.

Hi @mark_steelman,

Because of the nature of apps being “sandboxed,” you can’t directly share assets between them. I suppose one workaround would be to manage those assets remotely (on a server somewhere) and then, for each app, download those assets into the sandbox and use them. This approach isn’t too complicated really, and it would allow you to keep those assets up-to-date on the server, and with a little clever checking of the directory contents in the sandbox, check if new assets need to be downloaded/updated on each launch of the app.

Brent

Thank you, that is good advice.

Hi @mark_steelman,

Because of the nature of apps being “sandboxed,” you can’t directly share assets between them. I suppose one workaround would be to manage those assets remotely (on a server somewhere) and then, for each app, download those assets into the sandbox and use them. This approach isn’t too complicated really, and it would allow you to keep those assets up-to-date on the server, and with a little clever checking of the directory contents in the sandbox, check if new assets need to be downloaded/updated on each launch of the app.

Brent

Thank you, that is good advice.