Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Progress bar indicator

0 views
Skip to first unread message

Gunawan

unread,
Mar 29, 2000, 3:00:00 AM3/29/00
to

Hi

Anyone can help how to use Progress object, ex: I have 500 records, when I read that record from 1 to 500 progress bar show the progress indicator

Thank U
Gunawan


Mauro Patiño

unread,
Mar 30, 2000, 3:00:00 AM3/30/00
to
Set ProgressBar.Min := 0 and set ProgressBar.Max := 500 and also set ProgressBar.Position := 0

then after each loop iteration increment the ProgressBar.Position or if your using a loop like this

for i := 0 to 500 do
begin
....//your record code in here
....//or here
ProgressBar.Position := i;
end;

Andy Brown

unread,
Mar 30, 2000, 3:00:00 AM3/30/00
to
I think it's better to set
Set ProgressBar.Min := 0
ProgressBar.Max := 100
ProgressBar.Position := 0
then after each iteration calculate the percentage completed:
ProgressBar.Position := CURRENTRECORD * 100 div MAXRECORDS

Mauro Patiño <M-Pa...@govs.edu> wrote in message
news:38E2F961...@govs.edu...

Derek Spurlock

unread,
Mar 31, 2000, 3:00:00 AM3/31/00
to
Another possible way is to

1. Set the Min/Max properties as discussed earlier.
2. Set the Step property to 1
3. StepIt is a method of the ProgressBar Component this will increment the
position by the step property

One caveat is that depending upon the amount of processing going on you
might have to force a repaint of the form or Progress Bar
(Application.ProcessMessages should do the trick as well as a good practice
for Loops with involved processing which I assume you are doing or else what
is the need for progress bar )

Derek

Gunawan <gun...@romindo.com> wrote in message news:38e2cba9@dnews...

0 new messages