I have this JSON text and I can't figure out how to parse the "items" property to fill up a list of items
{
"response": {
"success": 1,
"current_time": 1445015502,
"items": {
"item1": {
"property1": 1,
"property2": "test",
"property3": 4.3
},
"item2": {
"property1": 5,
"property2": "test2",
"property3": 7.8
}
}
}
}
Those are my classes yet :
public class Item
{
public int property1 { get; set; }
public string property2 { get; set; }
public double property3 { get; set; }
}
public class Response
{
public int success { get; set; }
public string message { get; set; }
public int current_time { get; set; }
public List<Item> items { get; set; }
}
public class RootObject
{
public Response response { get; set; }
}
Also, no, it's not a error. There is no [ nor ] in the JSON text.
Also, the number of items in the JSON is undefined.