Help

Countdown timer based on an integer?

Topic Labels: Formulas
1344 2
cancel
Showing results for 
Search instead for 
Did you mean: 
Gareth_Procter
4 - Data Explorer
4 - Data Explorer

Hi all,

I’d appreciate help on this if at all possible?

I am trying to write a formula which counts down from a date field called ‘Last Service’ by a number of days as stipulated by a field called ‘Service Days’. Service Days is an integer which describes the number of days between each service activity. i.e. ‘14’ would indicate that there is a service every 14 days.

So if the ‘Last service’ was on 01/01/2020 (DD/MM/YY), and the ‘Service Days’ was 14, on 10/01/2020 the new formula would calculate ‘4’ (4 days left until next service).

I hope that makes sense and sorry if it is something that has been answered before - I tried to look but couldn’t find the answer! :slightly_smiling_face:

Gareth

2 Replies 2

@Gareth_Procter, If I understand what you’re trying to do, this formula should work.

DATETIME_DIFF(DATEADD(Date,{Service days},'days'),TODAY(),'days')

Thanks Nathalie - somehow you managed to understand the terrible description of my problem and give me an answer that works!!!