Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 4 Current »



Function: timeToSecs()

Converts a duration in hours, minutes and seconds into total number of seconds. The hours or minutes part of the duration can be omitted.

Padding zeroes, e.g. 02:34, are allowed.

Syntax

timeToSecs(durationString, separator)

ArgumentParameter TypesDescription
durationStringStringDuration in format hh:mm:ss, mm:ss or ss.
separatorStringSeparator used between the individual parts of the duration.

Examples

timeToSecs("01:00:03",":")

Returns 3603.


timeToSecs("2 03"," ")

Returns 123.


timeToSecs("43"," ")

Returns 43.

See Also

  • No labels