JSON with several kids

I’m trying to make JSON data with parent and several kids structure.
One parent would have one or several kids, and the number of kids are not fixed. Actually, I think I should make a method to add kids to their parents.
With below code, I see weird result.

  Dim root as new JSONItem
  Dim finalString As String
  Dim Parent as new JSONItem
  Parent.Value("H") =     "source"
  Parent.Value("P") =     "2"
  Parent.Value("IP") =       ""
  Parent.Value("V") =  "8"
  // first kids
  dim KidsArray as new JSONItem( "[]" )
  Dim Kids as new JSONItem
  Kids.Value("H") = "target1"
  Kids.Value("P") = "2"
  Kids.Value("IP") = ""
  Kids.Value("V") = "8"
  kidsArray.append Kids
  Parent.Value("Parents") = KidsArray
  root.append Parent
  // seconds kids...
  dim KidsArray2 as new JSONItem( "[]" )
  Dim Kids2 as new JSONItem
  Kids2.Value("H") = "target2"
  Kids2.Value("P") = "2"
  Kids2.Value("IP") = ""
  Kids2.Value("V") = "8"
  kidsArray2.append Kids2
  Parent.Value("Parents") = KidsArray2
  root.append Parent
It should be like below. 


Can you point me which part is wrong?

I’d like to help but the “it should be” example is not valid JSON so it’s hard to compare.

How about the JSON below?

      "H": "first",
      "P": "2",
      "IP": "",
      "V": "6",
      "parents": [
          "H": "second",
          "P": "2",
          "IP": "",
          "V": "6"
          "H": "third",
          "P": "2",
          "IP": "",
          "V": "6"

Try it in an online validator like http://jsonlint.com

Ah, you created two different parent arrays, but there should only be one.