+ Start a Discussion
Samuel JohnsonCBESamuel JohnsonCBE 

add 30 days to formula

I have a formula that I am using in a visualforce page.  I was able to finally able to get it to only show the date instead of the date time even though I was using just a date field.  Now I need to add 30 days to it.  here is my formula
{!  TEXT ( Month ( DATEVALUE (account.Archieved_Date__c ))) &"/"&  TEXT( DAY(DATEVALUE( account.Archieved_Date__c+30  ))) &"/"& TEXT(YEAR(DATEVALUE( account.Archieved_Date__c)))  }

I also tried it like this...
{!  (TEXT ( Month ( DATEVALUE (account.Archieved_Date__c ))) &"/"&  TEXT( DAY(DATEVALUE( account.Archieved_Date__c  ))) &"/"& TEXT(YEAR(DATEVALUE( account.Archieved_Date__c)))  + 30) }
Martijn SchwarzerMartijn Schwarzer
Hi Samuel,

Please take a look at the following article. It explains exactly what you are trying to do:


Good luck and happy coding!

Best regards,
Martijn Schwärzer

P.S. If my answer helps you to solve your problem please mark it as best answer. It will help other to find best answer.
santanu boralsantanu boral
You can simply use: account.Archieved_Date__c + 30

By the way, date format can be seen based on locale