Jump to content

UniDbgrid slow and does not work when query open on treevew change


Ulugbek

Recommended Posts

procedure THomeFrame.UniBitBtn3Click(Sender: TObject);
begin
  UniMainModule.qryGoodsDT.Close;
  UniMainModule.qryGoodsDT.Active:=false;
  UniMainModule.qryGoodsDT.SQL.Clear;
  UniMainModule.qryGoodsDT.SQL.Add('select * from goods');
  UniDBGrid1.Refresh;
  UniDBGrid1.DataSource:=UniMainModule.DataSource1;
  UniMainModule.qryGoodsDT.Active:=True;
end

Unidbgrid Freezes why i cannot understand..

Link to comment
Share on other sites

Hi.

 

Why you made UniDBGrid1.Refresh before set datsource and open dataset? Since dataset opened after it been closed, UniDBGrid1.Refresh is not necessary.
Try UniDBGrid1.Refresh after open dataset or remove it;

Link to comment
Share on other sites

  • 4 years later...

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...