Description
Use the Utils.Timers
property to obtain the scripting interface to the Timers
object. This object lets you create, delete and modify timers in your scripts.
Declaration
Applies To
The property is applied to the following object:
Property Value
A reference to the Timers
object.
Example
The code below demonstrates how you can use the Utils.Timers
property to obtain the Timers
collection and how to obtain the desired Timer
object from this collection.
JavaScript, JScript
function TestProc()
{
// Obtains the Timers collection
TimersCollection = Utils.Timers;
// Obtains the first object in the Timers collection
Timer = TimersCollection.Items(0); // Obtains a timer by its index or name
// ...
}
Python
def TestProc():
# Obtains the Timers collection
TimersCollection = Utils.Timers
# Obtains the first object in the Timers collection
Timer = TimersCollection.Items[0] # Obtains a timer by its index or name
# ...
VBScript
Sub TestProc
' Obtains the Timers collection
Set TimersCollection = Utils.Timers
' Obtains the first object in the Timers collection
Set Timer = TimersCollection.Items(0) ' Obtains a timer by its index or name
' ...
End Sub
DelphiScript
procedure TestProc;
var
TimersCollection, Timer : OleVariant;
begin
//Obtains the Timers collection
TimersCollection := Utils.Timers;
// Obtains the first object in the Timers collection
Timer := TimersCollection.Items[0]; // Obtains a timer by its index or name
// ...
end;
C++Script, C#Script
function TestProc()
{
var TimersCollection, Timer;
// Obtains the Timers collection
TimersCollection = Utils["Timers"];
// Obtains the first object in the Timers collection
Timer = TimersCollection["Items"](0); // Obtains a timer by its index or name
// ...
}