Current year in a formula

Hi,
I'd like to calculate the year of birth from the current age and the current year.

I know that with ${today} I get the date of today:
How can I have the ${current_year} instead?

Andrea

One option is this:
#1 type=calculate, current_year=today()
#2 then type=calculate, calculation=format-date(${current_year}, '%Y') <<
it formats the value of today() as year.
#3 do the math to calculate year of birth.
But since the handling of dates and times can be tricky and buggy
sometimes, when calculating the year of birth, i'd also use the num()
function, it won't do any harm :slight_smile:

ยทยทยท On Friday, April 8, 2016 at 7:26:13 PM UTC+2, ndr...@gmail.com wrote: > > Hi, > I'd like to calculate the year of birth from the current age and the > current year. > > I know that with ${today} I get the date of today: > How can I have the ${current_year} instead? > > Andrea