title: Read value from nested Json object
body: <p>I am trying to read a value from a nested Json object, but I am getting a Parse error:</p>
  <p>My Json object:</p>
  <pre><code>{
      &quot;MessageId&quot;: &quot;f6774927-37cf-4608-b985-14a7d86a38f9&quot;,
      &quot;Time&quot;: &quot;2017-04-06T16:28:38.0719933+02:00&quot;,
      
      &quot;Data&quot;:
      {
          &quot;ID&quot;:
          {
              &quot;value&quot;: &quot;0008044834&quot;
          },
          &quot;Carrier&quot;:
          {
              &quot;value&quot;: 0
          },
          &quot;Tool&quot;:
          {
              &quot;value&quot;: 0
          }
      }
  }
  </code></pre>
  <pre><code>          var myJsonString = File.ReadAllText(_currentDictory.FullName + @&quot;\test\&quot; + completeFilename);
  
  
              var myJObject = JObject.Parse(myJsonString);
  
  
              var serial = myJObject.SelectToken(&quot;Data.ID&quot;).Value&lt;String&gt;();
  
  </code></pre>
  <pre><code>System.InvalidCastException
    HResult=0x80004002
    Message=Cannot cast Newtonsoft.Json.Linq.JObject to Newtonsoft.Json.Linq.JToken.
    Source=Newtonsoft.Json
  </code></pre>
  <p>Reading other values such as &quot;MessageID&quot; works withou any problems, but as soon as I try to get &quot;Data.XYZ&quot; I am getting the error above.</p>