Excel Formula for Christmas and New Year

Chris Waller

Board Regular
Joined
Jan 18, 2009
Messages
183
Office Version
  1. 365
Platform
  1. Windows
Hi All,

I have the following formula =DATE(B50,12,25)+CHOOSE(WEEKDAY(DATE(B50,12,25)),1,0,0,0,0,0,2) which gives the date of the Christmas holiday. What I am trying to do in the next column is put a formula that will show Christmas Day if the date is the 25th December and Substitute Christmas Holiday if the date is after the 25th. I've tried all different combinations and I cannot get this to work. I am obviously doing something wrong because if I just use the date, I can get this to work.

Can someone give me any clues how to get the my formula for the days to work when using the formula above.

TIA
 

Excel Facts

What is the fastest way to copy a formula?
If A2:A50000 contain data. Enter a formula in B2. Select B2. Double-click the Fill Handle and Excel will shoot the formula down to B50000.
For your overall project, have you looked at NETWORKDAYS.INTL or WORKDAY.INTL that let you specify which holdays to account for and when the weekend is?
 
Upvote 0
How about
Excel Formula:
=IF(DAY(B51)=25,"xmas","subs")
where B51 has the other formula
 
Upvote 0
Glad we could help & thanks for the feedback.
 
Upvote 0
For your overall project, have you looked at NETWORKDAYS.INTL or WORKDAY.INTL that let you specify which holdays to account for and when the weekend is?
mikerickson,

Thanks for your prompt reply. I must admit that I am trying to do something as a matter of urgency, therefore I haven't had time to look at NETWEOKDAYS.INTL or WORKDAY.INTL yet, but will look at it when I have slightly more time than I do at present.

Thanks again for your help.
 
Upvote 0

Forum statistics

Threads
1,215,523
Messages
6,125,321
Members
449,218
Latest member
Excel Master

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top