+ Start a Discussion
karthikeya 2karthikeya 2 

Date field Adding by 1 day if sunday

How to write a formula for adding one day if the selected date is sunday

Thanks in advance.
Best Answer chosen by karthikeya 2
Vinoth Vijaya BaskerVinoth Vijaya Basker
Hello, 

Please find the below formula for criteria to check if the selected date is a Sunday,
if(CASE( 
MOD( DateField__c - DATE( 1900, 1, 8 ), 7 ), 
0, "Monday", 
1, "Tuesday", 
2, "Wednesday", 
3, "Thursday", 
4, "Friday", 
5, "Saturday", 
"Sunday" 
) = "Sunday", True, False)

And, add the below formula in Field update, 
DateField__c + 1

Thanks,
Vinoth