title: How to improve the performance of loading a data from MS access into DataGridView?
body: <p>I have a Windows .Net code to read the query from MS Access 2010 database and show it in the DataGridView.</p>
  
  <p>When I execute the query in MS Access it takes less than 7 seconds to show </p>
  
  <p>When the same query is called from .Net using the below code it takes around 50 seconds and it loads 1200 rows with 21 columns. Even for sorting a columns(clicking on column header) takes more than 15 seconds</p>
  
  <pre><code>Using Con As New OleDbConnection(Connection String)
        Using da As New OleDbDataAdapter(strQuery, Con)
              Using datatable As New DataTable("data")
                   da.Fill(datatable)
                   datagrid.DataSource = datatable
              End Using
         End Using
  End Using
  </code></pre>
  
  <p>Any way that i can improve the performance. Thanks in Advance!!!</p>