Q:

How to get values from multiple same tag names in xml?

This is my xml file:
<?xml version="1.0" encoding="UTF-8"?>
<!--Sample XML file generated by XMLSPY v5 rel. 4 U (http://www.xmlspy.com)-->
<decsts:EDI xmlns:decsts="http://www.testurl.com/schema/decsts" xmlns:cm="http://www.testurl.com/schema/common" xmlns:deccm="http://www.testurl.com/schema/deccm" xmlns:sau="http://www.testurl.com/schema/sau" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.testurl.com/schema/decsts
    D:\sns\trade\sau\rel1_0\schemas\IDEC\decSTS.xsd" decsts:docType="DEC" decsts:id="SAU20160603187160" decsts:msgType="H2HDECSTS">
        <decsts:record>
            <sau:payload xsi:type="decsts:declarationStatusType">
                <decsts:reference>
                    <decsts:userid>sdec001001</decsts:userid>
                    <decsts:acctId>rrni</decsts:acctId>
                    <decsts:docRefNo>20160603005992</decsts:docRefNo>
                    <decsts:regPort cm:type="4">23</decsts:regPort>
                    <deccm:declarationISN>1517791</deccm:declarationISN>
                </decsts:reference>
                   <decsts:statusInformation>
                    <decsts:statusDate>2016-06-03</decsts:statusDate>
                    <decsts:statusCode>1</decsts:statusCode>
                    <decsts:originalMsgId>SAU20160603187153</decsts:originalMsgId>
                </decsts:statusInformation>
                <decsts:statusErrorDetails>
                    <decsts:statusErrorCodeDetails>4</decsts:statusErrorCodeDetails> 
                    <decsts:remarks>goods are waiting for collection of customs fees</decsts:remarks> 
                </decsts:statusErrorDetails>

                <decsts:statusErrorDetails>
                    <decsts:statusErrorCodeDetails>5</decsts:statusErrorCodeDetails> 
                    <decsts:remarks>EXTRA NODE ERR</decsts:remarks>     
                </decsts:statusErrorDetails>

            </sau:payload>
        </decsts:record>
    </decsts:EDI>

I am trying to iterate the xml file using following code:
XDocument xdoc = XDocument.Load("TEST_XML.xml");
XNamespace ns = "http://www.TESTURL.com/schema/decsts";
var datas = from query in xdoc.Descendants(ns + "statusErrorDetails")
            select new
            {
              err_no = (string)query.Element(ns + "statusErrorCodeDetails"),
              err_desc = (string)query.Element(ns + "remarks")
            };

foreach (var item in datas)
{
  Console.WriteLine(item.err_no);
  Console.WriteLine(item.err_desc);
}

I am getting following output:

4  Error description 4

why it does not iterate next  node and values of child. Please help me to solve this problem, thanks. 

A:

I solved the issue, I tried following code and it is giving me the output I want:
XmlNodeList err_details = xmlDoc.GetElementsByTagName("decsts:statusErrorDetails");
foreach (XmlNode err_node in err_details)
{
   foreach (XmlNode err_items in err_node.ChildNodes)
   {
     Console.WriteLine(err_items.InnerText);
   }
}

