> Does anyone know how to solve this problem? i want that label1 shows the
> time that is going from 10 to 0, and when it reaches 0 it shows
[quoted text clipped - 4 lines]
> label1.caption = a
> loop until label1.caption = 0
The Timer control is not a count-down timer per se; rather, it is simply
a control that will "fire" (the Timer event will occur) every so often.
You tell it how often to "fire" using its Interval property. The number
you ASSIGN TO the Interval property is the number of milliseconds
between "firings"; so, when you assign the Interval property's value to
your variable 'a' in your code, the same number is being assigned over
and over as the loop continues on indefinitely. Try setting the Interval
property to the number of whatever's (seconds, minutes... you didn't
say) and keep subtracting one from a Static variable inside the event
(or a "global" variable declared in the form's General-Declaration
section) until that variable reaches zero. Be advised, though, the
"firing" of the Timer does not have a high priority; so, if your system
is real busy, it is possible for the Timer to "miss" firing every now
and again. That is, don't count on it being the most accurate timer in
the world.
Rick - MVP