I have the following code for displaying a progress bar whilst progressing through a file, this has served its purpose for some time now but wondered if there is a more efficient way to code this?
Thanks
Code:
repeat
ProgressBar1.Position := Round((Sourcefile.Position/Sourcefile.Size) * 100);
Application.ProcessMessages;
...some code other here
until Sourcefile.Position >= Sourcefile.Size;
Thanks