【发布时间】:2018-01-07 18:51:30
【问题描述】:
我有这个 JSON:
{"JOE":{"id":7,"age":"23"},"BILLY":{"id":8,"age":"29"}}
我有this solution for a more simple JSON structure posted by RajN。
Dim j1 As String = "{ "JOE"":""0.90000000"",""JOE"":""3.30000000"",""MONROE"":""1.20000000""}"
Dim dict = JsonConvert.DeserializeObject(Of Dictionary(Of String, String))(j1)
For Each kvp In dict
Console.WriteLine(kvp.Key & " - " + kvp.Value)
Next
我正在寻找如何处理新的 JSON 数据。 提前致谢
【问题讨论】:
-
现在你需要一个类来保存多位数据。您应该对使用 JSON 进行一些研究,这样您就不必一遍又一遍地问同样的问题,只有很小的变化
-
We both know thats not true 而是您有不了解您所获得的内容(然后猛烈抨击)的历史。再一次,没有人阻止你——如果你想存储更多的数据,你将需要一个类来保存它们。现在,愿 Google 与您同在。