Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi, I set a variable in my load script and i want use it in a calendar objetc ad in expressions.
Let Data_riferimento = date(today(0).'DD/MM/YYYY');
When i use the variable in my Calendar Object is show correctly
but after the load script and i use the variable in an expression it's no working
The first expression is (year(date($(Data_riferimento),'DD/MM/YYYY'))) & ' (YTD)' and i expect 2021 instead 1899.
Only if i select le date on the calendar object the date then then expression works.
Where is my mistake ? I need that after the load the variable is equal the formula date(today(0).'DD/MM/YYYY') and the expression wotks correctly.
Thanks
Hi @Corona7
For your expression, $() not required. try like below
= (year(date(Data_riferimento,'DD/MM/YYYY')))
I see two possible issues with your expression. Try this adjusted version.
year(date#('$(Data_riferimento)' ,'DD/MM/YYYY')) & ' (YTD)'
Thanks Mayil Vahanan, it's works! 👍
Thanks Vegar! It's works! 👌