c# 读取json字符串节点内容
c# 读取json字符串节点内容
string jsonstr = "{\"voiceprompt_callback\": {\"result\": \"1\",\"accept_time\": \"0\"}}"; var ty = JsonConvert.DeserializeObject(jsonstr); Newtonsoft.Json.Linq.JObject js = ty as Newtonsoft.Json.Linq.JObject; Newtonsoft.Json.Linq.JToken model = js["voiceprompt_callback"]; string c1 = model["result"].ToString(); string c2 = model["accept_time"].ToString();