Yes, it has to be stored locally.
Ok, so I built two apps to see if I could pass data between them. Long story short it can’t be (easily) done. It specifically says in the docs:
You cannot use the TinyDB to pass data between two different apps on the phone, although you can use the TinyDB to share data between the different screens of a multi-screen app.
If you think about it from a security perspective, it would be a terrible idea to allow one app access data that was stored by another app.
In the screenshot below I’ve added the
File component. Perhaps as a work-around you could store you data as as .csv or similar directly in the file system, this way it would be accessible to both (well, all!) apps.
también puede utilizar esta extensión pasa obtener la tinydb completa
what about having only one app and inside the app a menu to choose between “app 1” and “app 2”?
I think they have to make 1 app for the user and the other is admin
The apps are on one device.
I think, this is no solution. I would do it but meanwhile my app has over 5.000 blocks. So I plan to make another app with other/or new features for customers, but the should have acces to the same cients as they use in app 1.
It’s difficult to add more blocks, because I don’t now when appybuilder hangs up. I already have the problem that live testing is no more working (neither with wlan nor with usb)
I think it is best to use firebase or online server, but if you need offline solution then you can use text file. The text file can consist of a list. Text file can be accessed by multipe apps. It is persistent and you can easily back it up by upload it. You can read the text file as a list and treat list item index as a tag.
Thanks for the info, but the textfile could be read from everyone.
you might want to follow tip 3
It’s difficult to add more blocks, because I don’t now when appybuilder hangs up. I already have the problem that live testing is no more working
try to split screens with too much blocks…
In couple of days, We’ll have a new minor-release today will help with blocks performance and may help your situation.
Well, you can use some blocks for abstraction or maybe encryption if you want to protect the text contents. Taifun has an extension for encryption.
Let me add to the discussion that while I was checking the tag and values during debugging my app I found that it had tags and values in it from a completely different app, which was not running at the moment?? To be more precise it has tags of 2 other apps in it?
I used the .ClearAll to get rid of the old ones. And can’t tell you how they sticked in there (maybe the app crashing ?).
see the documentation http://ai2.appinventor.mit.edu/reference/components/storage.html#TinyDB
When you are developing apps using the AI Companion, all the apps using that Companion will share the same TinyDB. That sharing will disappear once the apps are packaged and installed on the phone. During development you should be careful to clear the Companion app’s data each time you start working on a new app.
I replied on the mail… But as I stated there, it was the “discovery” of the weird tags that led me to this topic.
No, I noticed it only once and came here (this topic) while trying to find out what was going on. I worked on a few apps over a longer period.