title: Parsing JSON Visual Studio C# vs VB
body: <p>I'm having problems parsing some JSon (from an HttpRequest. The received string is :</p>
  <pre><code>{{
  &quot;@odata.context&quot;: &quot;https://xxx/$metadata#customers(id,name,nbuys,domestic)&quot;,
    &quot;value&quot;: [
     {
    &quot;@odata.etag&quot;: &quot;W/\&quot;186553045\&quot;&quot;,
    &quot;id&quot;: &quot;bb1d4f0b&quot;,
    &quot;name&quot;: &quot;John Smith&quot;,
    &quot;nbuys&quot;: 5,
    &quot;domestic&quot;: true
  },
  {
    &quot;@odata.etag&quot;: &quot;W/\&quot;186553045\&quot;&quot;,
    &quot;id&quot;: &quot;bgjf4f0a&quot;,
    &quot;name&quot;: &quot;Jane Doe&quot;,
    &quot;nbuys&quot;: 8,
    &quot;domestic&quot;: false
    }
    ]
  }}
  </code></pre>
  <p>I successfully deserialize the string in C# using  NewtonSoft:</p>
  <pre><code>var J  = JsonConvert.DeserializeObject( jsonstring);
  </code></pre>
  <p>then I can iterate through each customer</p>
  <pre><code>For Each (item in J.value.Children())   
  {
      console.WriteLine(item.name);
   }
  </code></pre>
  <p>This works fine, but I need to do the same in Visual Basic. I get the same deserialized object:</p>
  <pre><code>Dim J as JObject = JsonConvert.DeserializeObject( jsonstring)
  </code></pre>
  <p>but I can't get the following to work</p>
  <pre><code>Foreach item In J.value.Children()
       console.WriteLine(item.name);
  
  next
  </code></pre>
  <p>This doesn't work. I've tried using various J objects without any luck. The only thing I've been able to get is</p>
  <p>dim i  as integer = J.Count</p>
  <p>What am I doing wrong? Thanks for helping</p>