I have a json file like below:
[
{
"00001" : "value1"
},
{
"00002" : "value2"
},
{
"00003" : "value3"
}
]
How to deserialize json like this?
I have a json file like below:
[
{
"00001" : "value1"
},
{
"00002" : "value2"
},
{
"00003" : "value3"
}
]
How to deserialize json like this?
After 1 hour search, I finally fixed it out.
string testJson = "[{\"00001\":\"value1\"},{\"00002\":\"value2\"},{\"00003\":\"value3\"}]";
var output = JsonReader.Deserialize<object[]>(testJson);
foreach(Dictionary<string, object> province in output){
foreach(var item in province)
Debug.Log(item.Key + ":" + item.Value);
}