2013-09-03 11 views
5
  1. contacts.jsoncome ottenere i dati JSON in cascate mora

    { "GetCategoryResult": [ { "CategoryID": "3", "NomeCategoria": "News", "countryID" : "1", "Risultato": "OK"}, { "CategoryID": "4", "NomeCategoria": "quotidiano", "countryID": "1", "Risultato": "OK"}, {"IDCategoria": "5", "NomeCategoria": "Thanthi", "CountryID": "1", "Risultato": "OK"}, {"IDCategoria": "1", "NomeCategoria": " Giornale "," CountryID ":" 1 "," Risultato ":" OK "}, {" IDCategoria ":" 2 "," CategoriaName ":" Magazine "," CountryID ":" 1 "," Risultato ": "OK"} ] }

  2. main.qml

    titolo: ListItemData.GetCategoryResult.CategoryName

informi come implementare questa linea in QML ---- ---->title: ListItemData. ????

risposta

4

ListItemData.GetCategoryResult [i] darà u-esimo relativa variante alla posizione che JSON

per ottenere titolo come "quotidiano"

uso ListItemData.GetCategoryResult [1] .CategoryName

Problemi correlati