December 23, 2022, 7:53pm
I’m stuck at a problem with Firebase and Kodular…
It’s like this:
I have a VALUE as list>
I use STORE to Firebase>
I get that VALUE from Firebase and it sends me a STRING.
The real question is: How can I save list format in Firebase then get the list from Firebase?
this is what is saves on Firebase:
And I want to get this as a LIST, then UPDATE this text (in app) and SAVE it again as a LIST and so on…
Thank you very much!
you want to store multiple values inside one tag…?
December 25, 2022, 1:07pm
I have one
TAG, in this case it is “ FAVORITES”.
Inside FAVORITES i would like to store: “ aa,bb,cc,dd,ee,ff” (multiple values).
My question is:
How can I upload to Firebase values like this:
Firebase editing mode:
but not like this:
nor(as it saves now)
or any other format
December 25, 2022, 2:50pm
Ok, I’m noob!
You don’t have to save that format on Firebase because you can transform it.
You get data as it is from Firebase:
[“ - value1”,“ value2”,…] string_format
Some check is
list_empty then create empty_list
If list !empty then convert your string to a list by segmenting
the text (delete [ and ] so you have “value1”,“value2”… (exactly what requires). list from CSV row text Now you have a list:
(value1 value2 value 3 … …) and you can add values, remove, etc. Save it normally and it will save as a
list_format on Firebase
You can close this topic!
December 26, 2022, 3:38am
You can always use the JsonTextDecode block in the Web component to convert a JSON string like
["test", 123] to an App Inventor value. It does all the job, and you do not need to deal with the strings.