All Telerik .NET tools and Kendo UI JavaScript components in one package. Now enhanced with:
i somehow canĀ“t reach the objects in a nested json. I easily can reach the element test, but how to reach this_month inside "stats"? this is my json:
{"test":"OK","stats":{"this_month":"1653","this_week":"1653"}}
sorry, accidentialy posted. here is my code:
var oResponseBody = oSession.GetResponseBodyAsString();
JSON.JSONParseResult oJSON = JSON.JsonDecode(oResponseBody) as JSON.JSONParseResult;
Hashtable oObj = oJSON.JSONObject as Hashtable;
oObj["stats"]["this_month"] = "changed";
var modBytes = Fiddler.WebFormats.JSON.JsonEncode(oObj);
// Convert json to bytes, storing the bytes in request body
var mod = System.Text.Encoding.UTF8.GetBytes(modBytes);
oSession.ResponseBody = mod;