here you can do something like the following to the example could help you replace .. structure / sample your text Jason
lets say my json script is as follows
{ "some_number": 253.541, "date_time": "2012-26-12T11:53:09Z", "serial_number": "SN8675309" "more_data": { "field1": 1.0 "field2": "hello JSON Deserializer" } }
assign json jsonText to a variable and pass it to the next c # code
using System.Web.Script.Serialization; var jsonSerialization = new JavaScriptSerializer(); var dictObj = jsonSerialization.Deserialize<Dictionary<string,dynamic>>(jsonText); Console.WriteLine(dictObj["some_number"]); //outputs 253.541 Console.WriteLine(dictObj["more_data"]["field2"]); //outputs hello JSON Deserializer ); using System.Web.Script.Serialization; var jsonSerialization = new JavaScriptSerializer(); var dictObj = jsonSerialization.Deserialize<Dictionary<string,dynamic>>(jsonText); Console.WriteLine(dictObj["some_number"]); //outputs 253.541 Console.WriteLine(dictObj["more_data"]["field2"]); //outputs hello JSON Deserializer
source share