I have a DataTable, fully populated, which I want to set to a DatagridView:
gdv.DataSource = dt;
However, this is painfully slow. The filling of the DataTable is very quick, but just this one line above takes ages. Is there any way to speed this up or perform it in another thread?
There is no interaction after this point. Just the simple statement above!
Thanks.
Check the formatting options, especially the
Fill-related properties. Those are AutoSizeColumnMode and the individual column styles.Adjusting columnwidths for all rows involves a lot of calculation.