title: Convert dynamic query result to a list in order to bind to a grid
body: <p>I am using the following query in vb.net using the System.Linq.Dynamic library to bind the result to a gridview</p>
  
  <pre><code>Dim customers = model.Customers _
      .OrderBy(sortExp + " " + sortOrder) _
      .Select("new (CustomerID, CompanyName, ContactName, ContactTitle, Address, City,     Region, PostalCode, Country, Phone, Fax)")
  
  grdCustomers.DataSource = customers
  grdCustomers.DataBind()
  </code></pre>
  
  <p>The following error is displayed</p>
  
  <p><strong>Data binding directly to a store query (DbSet, DbQuery, DbSqlQuery) is not supported. 
  Instead populate a DbSet with data, for example by calling Load on the DbSet, 
  and then bind to local data. For WPF bind to DbSet.Local. 
  For WinForms bind to DbSet.Local.ToBindingList().</strong></p>
  
  <p>The result returned is of type DbQuery but I cannot do a ToList() on the result.</p>
  
  <p>There must be a cleaner way to create a list instead of interating through the customers and creating the list manually.</p>