I'd like to be able to get/set the property values of a
:
{
"payload":[
{
"a":"yes",
"b":"no",
"c":"maybe"
},
{
"a1":"agg",
"b":"no",
"c":"maybe"
},
{
"a":"L",
"b":"k",
"c":"maybe"
}
]
}
I'd like to be iterate through all of the a
and get/set its values. In pseudocode something like this:
foreach(var jsonObject in payload)
{
jsonObject.a = "ZZZZZZZZ";
}
The resulting structure would be something like this:
{
"payload":[
{
"a":"ZZZZZZZZ",
"b":"no",
"c":"maybe"
},
{
"a1":"agg",
"b":"no",
"c":"maybe"
},
{
"a":"ZZZZZZZZ",
"b":"k",
"c":"maybe"
}
]
}
How do we access values within objects within arrays?
Please note that the schema is dynamic.