title: Cannot implicitly convert type 'System.Collections.Generic.IEnumerable>>' to 'System.Collections.Generic.IEnumerable'. An explicit conversion exists
body: <p>I am using below query to return all the child elements and then based on child node i want to fetch the result.</p>
  
  <pre><code>XElement rootElement = XElement.Load(@"E:\Samples\TestConsole\TestConsoleApp\TestConsoleApp\XMLFile1.xml");
          IEnumerable&lt;XElement&gt; lv1s = from lv1 in rootElement.Descendants("A")
                     where lv1.Attribute("Code").Value.Equals("A001") &amp;&amp; lv1.Attribute("Lable").Value.Equals("A001")
                     select (from ltd in lv1.Descendants("A1")
                             where ltd.Attribute("Code").Value.Equals("001")
                             select ltd.Elements()).ToList();
  </code></pre>
  
  <p>But  still i am having following error.</p>
  
  <p><code>Cannot implicitly convert type 'System.Collections.Generic.IEnumerable&lt;System.Collections.Generic.List&lt;System.Collections.Generic.IEnumerable&lt;System.Xml.Linq.XElement&gt;&gt;&gt;' to 'System.Collections.Generic.IEnumerable&lt;System.Xml.Linq.XElement&gt;'. An explicit conversion exists (are you missing a cast?)</code></p>
  
  <p>Please let me know.</p>
  
  <p>i want my value of lv1s["A11"], lv1s["A22"]</p>
  
  <p>below is my xml</p>
  
  <pre><code>    &lt;?xml version="1.0" encoding="utf-8" ?&gt;
  &lt;Document&gt;
    &lt;A Code="A001" Lable="A001"&gt;
      &lt;A1 Code="001"&gt;
        &lt;A11&gt;A1&lt;/A11&gt;
        &lt;A22&gt;A2&lt;/A22&gt;
        &lt;A33&gt;A3&lt;/A33&gt;
      &lt;/A1&gt;
    &lt;/A&gt;
    &lt;A Code="A002" Label="A002"&gt;
      &lt;A1 Code="002"&gt;
        &lt;A44&gt;A44&lt;/A44&gt;
        &lt;A55&gt;A55&lt;/A55&gt;
      &lt;/A1&gt;
    &lt;/A&gt;
  &lt;/Document&gt;
  </code></pre>
  
  <p>Please let me know.</p>
  
  <p>Also How i can handle "Enumeration yielded no results" as count 0 in my return list since it's giving count>0 if this error occurs.</p>