Skip to content

FormatTime - Built-in Formatting Function

Purpose

Formats a time using the Windows locale settings or supplied mask.

Syntax

FormatTime(exp,type[,mask])

Arguments

Argument Required Description
exp Yes The time to be formatted
type Yes The format type from one of the predefined time formats
mask No A string with the time mask to use

Example

// format the time using a supplied mask
Return FormatTime({PurchaseOrderHeader.ModifiedDate},drCustomTime,'HH:mm')

Notes

  • When exp cannot be converted to a time, a runtime error is generated.
  • When type cannot be converted to an integer, a runtime error is generated.
  • When mask cannot be converted to a string, a runtime error is generated.