title: Cannot implicitly convert type 'System.Linq.IQueryable to System.Data.DataTable'. An explicit conversion exists
body: <p>I am trying to create a Data Table using my Entity Framework with this code</p>
  
  <pre><code>private DataTable dtSubjects
      {
          get
          {
              object obj = this.Session["Subjects"];
              if ((!(obj == null)))
              {
                  return ((DataTable)(obj));
              }
              DataTable myDataTable = new DataTable();
              myDataTable = from r in DbContext.Subjects
                            where r.LinkAnalysisId == LinkID
                            select r;
  
              this.Session["Subjects"] = myDataTable;
              return myDataTable;
          }
      }
  </code></pre>
  
  <p>However I get this  error.
  Cannot implicitly convert type 'System.Linq.IQueryable to System.Data.DataTable'. An explicit conversion exists</p>
  
  <p>I have tried casting to a list but that does not work.  Can someone please shed some light on this issue?</p>
  
  <p>Thanks</p>