spurtniq
09-12-2003, 11:31 AM
What I'm trying to do is:
Have a loop repeat say, 25 times.
Within that loop, I want a countdown timer
up to 500, like so:
First loop
1 (outer)
480 to 500 (inner - timer 481, 482, 483, etc)
Second Loop
2 (outer)
460-500 (inner - timer 461, 462, 463, etc)
Third Loop
3 (outer)
440-500 (inner - timer 441, 442, 443, etc)
...
Final Loop
25 (outer)
1-500 (inner - timer 1, 2, 3, etc)
based on simple math (25x20 = 500)
So every iteration should be a multiple of 20
Every time the outside loop increments the
inside countdown timer interval should get larger
thereby SLOWING the process down. Once the
outside loop reaches 25 I want the process to stop.
So it starts out fast, small interval and then slows
down, large interval, and ultimately stops.
I'm having problems wrapping my mind around
the code.
Should it be some if-then loops, if-then-else, for,
or while loops or something completely different?
Thanx.
Have a loop repeat say, 25 times.
Within that loop, I want a countdown timer
up to 500, like so:
First loop
1 (outer)
480 to 500 (inner - timer 481, 482, 483, etc)
Second Loop
2 (outer)
460-500 (inner - timer 461, 462, 463, etc)
Third Loop
3 (outer)
440-500 (inner - timer 441, 442, 443, etc)
...
Final Loop
25 (outer)
1-500 (inner - timer 1, 2, 3, etc)
based on simple math (25x20 = 500)
So every iteration should be a multiple of 20
Every time the outside loop increments the
inside countdown timer interval should get larger
thereby SLOWING the process down. Once the
outside loop reaches 25 I want the process to stop.
So it starts out fast, small interval and then slows
down, large interval, and ultimately stops.
I'm having problems wrapping my mind around
the code.
Should it be some if-then loops, if-then-else, for,
or while loops or something completely different?
Thanx.