Year method

Official Content
This documentation is valid for:

Returns the year number of a given date. If the received parameter is null, zero is returned.

Syntax

date-expression | datetime-expression.Year()

Type returned:
Numeric N(4)

Example

To obtain the current year and assign it to a variable:

&ThisYear = Today.Year()

A string displaying text next to the year:

&TxtYear = 'Year:' + str(&Today.Year())

Scope

Objects   Procedure object, Transaction object, Web Panel object

See also

TimeZone Support - General Considerations
Year function
Month method
Day method





Was this page helpful?
What Is This?
Your feedback about this content is important. Let us know what you think.