title: Fill Datatable from linq query
body: <p>i am using the below code </p>
  
  <pre><code>IEnumerable&lt;DataRow&gt; query = from c in at.appointmentcalendars.AsEnumerable() 
                               select c;
  
  DataTable dt = query.CopyToDataTable();
  </code></pre>
  
  <p>But i am getting the below error </p>
  
  <blockquote>
    <p>Cannot implicitly convert
    type <code>'System.Collections.Generic.IEnumerable&lt;appointmentcalendar&gt;'</code> to
    <code>'System.Collections.Generic.IEnumerable&lt;System.Data.DataRow&gt;'</code>. An
    explicit conversion exists (are you missing a cast?)</p>
  </blockquote>