Need help regarding Firebase

then why this code Materia: posted earlier?

tag

You mean you do not know where some of the Blocks are?

because it was just another atempt to get it to work.

from now on, this is the working piece

yes, things like web1 or even jsonText....

Web is in the Connectivity Palette; jsonText is your FirebaseDB.GotValue. It arrives from Firebase as a json list. His Blocks decode
jsonlist (which is the json) to something readable. At the moment, you are not decoding and sorting the pieces for display :cry:

i undestand, and how exactly would i sort that out? to make it readable? Thats the last piece of problem that i am having (at least about this)

One way is to make the json readable is to reproduce Tim's code. I know it is difficult to understand; Tim is using advanced coding techniques . I don't understand the parts by inspection. :astonished:

@TIMAI2 can you provide Marcos some draggable code please if you have time?

These blocks ?

Thanks Tim.

You know how to use them Marcos?

Left click one of the two images.
It becomes enlarged
Drag the image to the Blocks screen

Did that work @Xispitojm ?

magicDecode

Hopefully after adding a Web component to the Designer you get the above (or something similar..it was difficult to read the json in the image you provided)

i copied the code, give me a moment, ill try it out

whats the web component? i cant find it anywhere

It’s in the Connectivity drawer used for decoding and receiving internet data like JSONs. If you don’t know where a component is or if you want to save time, you can search it in the Palette.

thanks, got it

if i wanted to show the data in a single listview, how would i update the code for it? Cuz in your code, you use Label1 and Label2, i could use it also, but since u showed only the code, i have no idea where label1 and label2 are

Label1 is just for showing what comes back as a raw value from firebase.

Label2 "could" be replaced with Listview.Elements.

image
image
Would it be as easy as this?

Well, did you try it?

i did, and nothing showed up

What do you see in label4 ?

"Text for label4" Looks like its not even updating

OK:

  1. You are not getting any data back from firebase....
  2. I have just reviewed the blocks, and itemList is not an AI2 list, it is a string. You would need to reorganise the blocks to make it an AI2 list so that it can be shown in a listview, or build listview elements from the returned data, and make a list out of them.

oops, i forgot to get tags when i inicialized the screen.. :rofl:

but still,errors are showing up

it basically showed everything on my database, as an error