GetTimeDiff method: Util class

Syntax

GetTimeDiff(DateTime1, DateTime2)

Description

Use the GetTimeDiff method to determine the difference between two DateTime values.

Parameters

Parameter Description

DateTime1

Specify the starting date and time as a DateTime value.

DateTime2

Specify the ending date and time as a DateTime value.

Returns

A number specifying the difference between the two DateTime values (in seconds.)

Example

In the following example, &nPeriod is 15 minutes.

&DTM1 = DateTimeValue("10/09/97 10:35:36");
&DTM2 = DateTimeValue("10/09/97 10:50:36");

Local number &nPeriod = &myUtil.GetTimeDiff(&DTM1, &DTM2) / 60;