Search code examples
app-inventor

App Inventor 2 extract numbers in JSON format


How to possible extract numbers in JSON format ? I found a sample but i don't know how it work. I show you here.

Sample JSON: {"out":9} {"out":76} {"out":458}

JSON To TEXT


Solution

  • use the JsonDecode block from the web component to convert the JSON into a list of lists, then see the following examples how to extract your values

    generally how to work with lists and list of lists:
    How to work with Lists by Saj
    How to work with Lists and Lists of lists (pdf) by appinventor.org

    JSON and list of lists: example1 and example2
    Easy to decode large information with JSON format by Carlos
    A general purpose JSON browser routine by ABG