Delphi Pause Program
I like a delay or pause. Keeps windows messages happening but delays or pauses the program. I know there may be some contention about this, but I use it a lot and have never had an issue.
See More On Stackoverflow


Give More Feedback
Board index » delphi » 'pause' Scott Earne. Delphi Developer. Wed, 18 Jun 1902 08:00:00 GMT. It changes the way the program writes to the screen. I have tried several ways to try to detect if the webbrowser is finished loading a website. I can't seem to find a solution that always works though.
Procedure Delay(MSecs: Cardinal); var FirstTick, CurrentTick: Cardinal; Done: Boolean; begin Done:= FALSE; FirstTick:= GetTickCount; While Not Done do begin Application.ProcessMessage s; CurrentTick:= GetTickCount; If Int64(CurrentTick) - Int64(FirstTick) = (Int64(FirstTick) - High(Cardinal) + MSecs) Then Done:= TRUE; End Else If CurrentTick - FirstTick = MSecs Then Done:= TRUE; end; end; usage: delay(1000); button1.click; John.