Infinite Countdown

If I want to have a countdown for Christmas, that’s easy. I can countdown to Dec 25th. But on Dec 26th, that countdown should automatically reset back to 364. I haven’t seen that Coda can handle dates on the calendar unless there is a definitive year attached. Is there a way to do this?

Hey @Chad_Sakonchick – Here’s a working formula I’ve come up with:

If(Now()>ToDate(Concatenate(Year(Now()),"/12/25")), ToDateTime(Concatenate("12-25-",Now().Year().Right(2)+1," 00:00:00"))-Now(), ToDateTime(Concatenate("12-25-",Now().Year().Right(2)," 00:00:00"))-Now())

What this is basically saying is… IF now is after December 25, show me the countdown to next year’s christmas. Otherwise show me countdown to this year’s Christmas.

Here’s the doc where I worked it out: