Post

2 followers Follow
0
Avatar

Formula for # of Days

Need help writing a formula that will return the number of dates between a date field and today. 

I have a date field and a # of days field.

Samantha Bell Answered

Please sign in to leave a comment.

1 comment

0
Avatar

Hello Samantha,

There's two functions that can do this - DateDiff() and DateSubtract().

DateDiff() returns a Numeric value and can calculate the date difference in years, months, weeks or days:

Example: DateDiff(Now(), $ThisIsYourDateField, 'd') 

DateSubtract() returns a Duration value and can calculate the date difference in working days or non-working days:

Example: DateSubtract(Now(), $ThisIsYourDateField, TRUE)

I hope this helps,

Roland

Roland Pumputis 0 votes
Comment actions Permalink