when use JsonConvert.DeserializeObject(str)
to parse a json string, the playerInfo
parsed as string, how to remove the "
in the start and the end of playerInfo so it can be parsed as object?
below link is the full json text
when use JsonConvert.DeserializeObject(str)
to parse a json string, the playerInfo
parsed as string, how to remove the "
in the start and the end of playerInfo so it can be parsed as object?
below link is the full json text
try this
JArray jArr = (JArray)JObject.Parse(str)["pointList"];
foreach (JObject jObj in jArr)
foreach (var prop in jObj.Properties())
if (prop.Value.Type == JTokenType.Object)
if (prop.Value["playerInfo"] != null)
prop.Value["playerInfo"] = JObject.Parse((string)prop.Value["playerInfo"]);