title: Get last child element using XmlReader
body: <p>Say I have this XML:</p>
  
  <pre><code> &lt;fields&gt;
          &lt;field fieldid="fdtElem3Group"&gt;
            &lt;value actionid="1" actiontype="review"&gt;123456789&lt;/value&gt;
            &lt;value actionid="2" actiontype="review"&gt;123456789&lt;/value&gt;
            &lt;value actionid="3" actiontype="review"&gt;123456789&lt;/value&gt;
            &lt;value actionid="4" actiontype="review"&gt;123456789&lt;/value&gt;
            &lt;value actionid="5" actiontype="review"&gt;123456789&lt;/value&gt;
          &lt;/field&gt;
          &lt;field fieldid="fdtElem7Group"&gt;
            &lt;value actionid="1" actiontype="review"&gt;29/10/75&lt;/value&gt;
            &lt;value actionid="2" actiontype="review"&gt;29/10/74&lt;/value&gt;
            &lt;value actionid="3" actiontype="review"&gt;29/10/74&lt;/value&gt;
            &lt;value actionid="4" actiontype="review"&gt;29/10/76&lt;/value&gt;
            &lt;value actionid="5" actiontype="review"&gt;29/10/74&lt;/value&gt;
          &lt;/field&gt;
        &lt;/fields&gt;
  </code></pre>
  
  <p>I'm trying to get the value of the last 'value' element of each respective 'field' element using <a href="https://msdn.microsoft.com/en-us/library/system.xml.xmlreader(v=vs.110).aspx" rel="nofollow noreferrer"><code>XmlReader</code></a>.  How would I do that please?  This doesn't work:</p>
  
  <pre><code>while (xmlReader.Read())
  {
      if ((xmlReader.NodeType == System.Xml.XmlNodeType.Element) &amp;&amp; (xmlReader.Name == "field"))
      {
          xmlReader.ReadToDescendant("value");
          while (xmlReader.ReadToNextSibling("value"))
          {
              //just iterate over until it reaches the end
          }
          xmlReader.Read();
          Console.WriteLine(xmlReader.Value);
      }
  }
  </code></pre>