hi! im looking to format date. [[Now.addDays(28).getFullYear()]]-[[Now.addDays(28).getMonth()]]-[[Now.addDays(28).getDate()]] gives me 2018-8-8, but i want it to show as 2018-08-08 ideas?
Date format missing numerals
nkrisc
#2
Try this:
[[('x0' + Now.addDays(28).getMonth()).slice(-2)]]
Repeat for day
EDIT: Should be -2
not 2
.
zariel
#3
tried it, didn’t work. now getting 2018-8-20 (since it adds to todays date.). Considering that month shows as “8” and no “08” i take it it didnt work
[[Now.addDays(28).getFullYear()]]-[[(‘x0’ + Now.addDays(28).getMonth()).slice(2)]]-[[(‘x0’ + Now.addDays(28).getDate()).slice(2)]]