Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How do I stop screen updates?

Status
Not open for further replies.

FrankThynne

Technical User
May 29, 2001
36
GB
I want to temporarily turn off screen updating while a series of tasks runs automatically, but can't find the appropriate procedure, method or property. (In VB it would, I think, be Application.Echo = False or something similar).
 
Hi,

if you mean that you donn't want to show the output to the screen while updating tables, you can do the following:
Code:
with CustTable do
begin
  DisableControls;
  try
    First;
    while not Eof do
    begin
     { Process each record here }
     Next;
    end;
  finally
    EnableControls;
  end;
end;

It wil stop the output to the controls connected to the database.

Steph [bigglasses]
 
Thanks for responding, Steph.

Your suggestion would be right if I were processing a dataset - but I'm not.

What I'm doing is processing a user-written script which is loaded into a memo control. In its normal mode of operation, I show the progress by selecting the statement being executed.

The script processor has evolved and now allows the user to start from a selected point and, to save writing new code, the earlier statements are handled as before but without execution - so showing the moving selection is inappropriate. I therefore wanted to avoid visibly updating the control until execution resumed. I tried disabling the control; this improved the behaviour a bit and selections weren't highlighted, but the control still scrolled as the selection point changed.

I suppose I could hide the control, but I didn't really want to.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top