I have the following array:
{
"customizedData":[
{
"key":"SubscriptionId",
"value":"xxxxxxxxxxxxxxxx"
},
{
"key":"OfferId",
"value":"xxxxxxxxxxxxxx"
},
{
"key":"SubscriptionName",
"value":"DYNAMICS 365 BUSINESS CENTRAL TEAM MEMBER"
},
{
"key":"Quantity",
"value":"6"
},
{
"key":"Status",
"value":"Suspended"
},
{
"key":"PartnerOnRecord",
"value":"None"
}
]
}
How do I access key the elements:
"key": "SubscriptionName", "value": "DYNAMICS 365 BUSINESS CENTRAL TEAM MEMBER"
At the moment I use: (string)t["customizedData"][2]["value"]
Are there any better ways?
Here's a link that may help you.
Accessing Data From JSON JavaScript | CodeHandbook