Articles

This example shows, how to lock refreshing of Edit component. Use LockWindowUpdate for this. When you will press button1 and, after that, button3, then you won't see 'Hello' string in Edit component.

procedure TForm1.Button1Click(Sender: TObject);
begin
  LockWindowUpdate(Edit1.Handle);
end;

procedure TForm1.Button3Click(Sender: TObject);
begin
  Edit1.Text:='Hello';
end;

procedure TForm1.Button2Click(Sender: TObject);
begin
  LockWindowUpdate(0);
end;