我有一个看起来像的字符串:
jQuery18309175745982483048_8380382834({"d":{"__type":"locatorservice.DataTemplate.LocatorResults","ResultData":[{"Address1":"Main Street 1","Address2":"","City":"New York","State":"SN","Zip":"04832","Country":"GER","Latitude":50.29482,"Longitude":12.3242,"StoreId":"32425"},{"Address1":"Main Street 3","Address2":"","City":"New York","State":"SN","Zip":"03242","Country":"GER","Latitude":54.29482,"Longitude":17.3242,"StoreId":"33434"}
现在我只想在一个foreach循环中获得纬度,经度和地址以及两者的城市。但是我怎么解析那个字符串呢?
答案 0 :(得分:0)
RootElement Result = JsonConvert.DeserializeObject<RootElement>(JsonString);
不要忘记using Newtonsoft.Json;