FormatDuration

The FormatDuration function converts a duration in seconds into a formatted date/time string.

Syntax

The FormatDuration function has the following syntax:

String = FormatDuration(Seconds)

Parameters

The FormatDuration function has the following parameter.

Table 1. FormatDuration function parameters

Parameter

Format

Description

Seconds

Integer

Number of seconds.

Return value

Formatted date/time string.

Example

The following example shows how to convert seconds into a formatted date/time strings.

Seconds = "41927";
Duration = FormatDuration(Seconds);
Log(Duration);

This example prints the following to the policy log:

Parser Log: 11:38:47s