ToDateString

function ToDateString(date: Date | any, locale?: string | null): string

The function ToDateString converts a date in accordance with a transferred localization into a string containing the date.

Parameter

Name

Type

Description

date

any

Text, numbers (milliseconds since 1/1/1970) or JavaScript date object.

locale

string

The localization variable as a string. If this is not specified, the currently active language will be used.

Return value

Type

Description

string

The date of the input value according to the localization in the form of a string.

NuGet package: Beckhoff.TwinCAT.HMI.Functions

ToDateString 1:

NuGet packages are available from version 1.12.

ToDateString 2:

Available from version 1.10