title: System.Xml.Linq.XElement>' does not contain a definition for 'First' and no extension method 'First' accepting a first argument of
body: <p>I am trying to change some custommessage encoder Using this blog</p>
  
  <pre><code>http://www.falconwebtech.com/post/2010/05/24/WCF-Interoperability-and-Extensibility-Part-Two.aspx
  </code></pre>
  
  <p>Here the author uses a extension method</p>
  
  <pre><code> xmlMessage.Descendants(sec + "Security").First().Add(samlXml);
  </code></pre>
  
  <p>What namespace do I use for this .First
  This is the error I am getting</p>
  
  <p>'System.Collections.Generic.IEnumerable' does not contain a definition for 'First' and no extension method 'First' accepting a first argument of 
    type 'System.Collections.Generic.IEnumerable' 
    could be found (are you missing a using directive or an assembly reference?)</p>
  
  <p>I have the following namespaces included</p>
  
  <pre><code>using System;
  using System.IO;
  using System.Security.Cryptography;
  using System.ServiceModel.Channels;
  using System.Text;
  using System.Xml;
  using System.Xml.Linq;
  using System.Reflection;
  using System.Collections.Generic;
  using System.Xml.XPath;
  using System.Security.Cryptography.Xml;
  using System.Security.Cryptography.X509Certificates;
  using Microsoft.Web.Services3.Security;
  using System.ServiceModel.Security;
  using System.IdentityModel.Tokens;
  </code></pre>
  
  <p>I could've done my research but I am taking the easy way</p>
  
  <p>Thank you</p>