Board index » delphi » Q: DBGrids slowing down table loops

Q: DBGrids slowing down table loops

Hi,

I have heard that setting the DataSource of DBGrids to NIL when looping
through a ttable's records significantly speeds up the process.  Does this
also apply if the DBGrid's forma is closed?

Which other tips (in addition to setting the ttable.Exclusive to TRUE) can I
use to speed up table access when I need to loop through and edit thousands
of records...?

Thanks for any hint

Regards

Tor

 

Re:Q: DBGrids slowing down table loops


Hi,

You can prevent the display in data aware components connected to a table as
follows:
Try
  Table1.DisableControls;
  // your code that manipulates the table
 Finally
  Table1.EnableControls;
end;
Best regards,
Karel Vandenhove

Tor Tveitane heeft geschreven in bericht <6m38rh$3...@forums.borland.com>...

Quote
>Hi,

>I have heard that setting the DataSource of DBGrids to NIL when looping
>through a ttable's records significantly speeds up the process.  Does this
>also apply if the DBGrid's forma is closed?

>Which other tips (in addition to setting the ttable.Exclusive to TRUE) can
I
>use to speed up table access when I need to loop through and edit thousands
>of records...?

>Thanks for any hint

>Regards

>Tor

Other Threads