You are viewing limited content. For full access, please sign in.

Question

Question

ADD_MONTHS

asked on August 23, 2019

I have a date field in my form in the format M/d/yyyy. I want to use ADD_MONTHS to add 24 montha to that date field. How do I do that?

 

Priya

0 0

Replies

replied on August 26, 2019 Show version history

Hi Priya

In your current date field, if you use the following in the formula field, it will automatically add 24 to the current date. =ADD_MONTHS(TODAY(),24)

If the user is going to select a date and then then you are going to generate the new date 24 months into a new date field, the formula in the new date field would be =ADD_MONTHS(ChosenDateVariable),24)

You cannot due this with the original date field as you cannot reference itself in a formula

2 0
replied on August 26, 2019

Any update please?

0 0
replied on August 26, 2019

Are you running into an issue using ADD_MONTHS(date, months)? You cant use the function in the same field, you would need to add a second field for the new date.

(as a side note, I would suggest not leaving "any updates please?" messages in a thread. When looking at the list of unanswered questions, it makes the thread look like it's had some activity, so it moves it down the list and makes it less visible for people looking to help)

0 0
replied on August 26, 2019

Thanks

0 0
replied on August 29, 2019

If I hard code a value like 24, it works. But, if I store 24 in a hidden field and use that variable, it does not work. Any help please?

 

THanks

Priya

0 0
replied on August 29, 2019

Is the field you put the Months in a Number Field. When using formula's in Forms, Use the Number Field when you are going to use formula's with numbers in calculations. Forms will not interpret a Number in a Single Line field as a number.

2 0
replied on September 3, 2019

Thanks

0 0
replied on August 23, 2019

Any update please?

 

Priya

0 1
You are not allowed to follow up in this post.

Sign in to reply to this post.