AMT Help Files

Timer

Description:

The Timer object adds a timer to the form. It must be added in the screen layout just like any other object but it will be invisible in AMT Screens and the Webclient. It has two properties, an Interval to set the time of the timer in seconds and Enabled which enables the timer when set to True.

The initial interval and enabled state must be set in the properties tab of the object inspector as shown.




When the countdown of the timer reaches zero an OnTimer event is generated. In the Events tab of the object
inspector an event routine has to be added to take action on the generated event in the code of the form.




Code examples:

In the code the timer can be stopped or started with the following code:

timer_0.enabled  := false

timer_0
.enabled  := true

The interval of the timer can be changed by setting the interval property to a new value.

timer_0.interval := 120



Toolbar button icon:

 

Properties:

 

Events:

 

Runtime properties: