Skip to main content

Date.Year

Returns the year component.

Syntax

Date.Year(
dateTime as any
) as number

Remarks

Returns the year component of the provided datetime value, dateTime.

Examples

Example #1

Find the year in #datetime(2011, 12, 31, 9, 15, 36).

Date.Year(#datetime(2011, 12, 31, 9, 15, 36))

Result:

2011

Category

Date