10
Answers

Deserialize JSON dynamic array

Tommy

Tommy

8y
513
1

Hey guys,

 I have JSON string:

 
{"results": {
"0001": [{
"type": "AA",
"Id": "420",
"service": false,
"description": "",
"imageUrl": "http://www.somelink.com/file.jpg",
"date": "1457608735000"
},
{
"type": "CC",
"Id": "114",
"service": true,
"description": "",
"imageUrl": "http://www.somelink.com/file.jpg",
"date": "1457611015000"
}]
}
}
 
In this example array 0001 will be dynamic id in numbers, it will be always random number. How can I deserialize this string into right order? I need to receive type, Id, service, description, imageUrl, date of the very last object (the one who's "type":"CC").
 
Please, somebody help. Thank you.

Answers (10)