I wan't to get all subnodes in a JSON file using JSON.NET is it possible ?
Here is my code :
Shared Function LoadBranch(ByVal branch As String, ByVal tv As TreeView)
Dim jsonstr As String = FileIO.FileSystem.ReadAllText(FileIO.FileSystem.ReadAllText(".\temp\localpath.txt"))
Dim obj As JObject = JObject.Parse(jsonstr)
Dim result As List(Of JToken) = obj.Children().ToList()
For Each item As JProperty In result
Dim rootName As String = item.Name
If branch = rootName Then
Dim root As TreeNode = tv.Nodes.Add(rootName)
For Each child In item.Children()
For Each jprop As JProperty In child
root.Nodes.Add(String.Format("{0} : {1}", jprop.Name, jprop.Value))
Next
Next
End If
Next
Return True
End Function