4-10 holiday schedule formula

Breizze1313

New Member
Joined
Sep 26, 2023
Messages
3
Office Version
  1. 2021
Platform
  1. Windows
I am trying to write a formula that shifts holidays that fall on Fridays or Saturdays to Thursdays. I have the formula to shift holidays that fall on Saturday or Sunday, but the shift to Thursday is alluding me. Please can anyone help with this??

The weekend shift to the Friday before or the Monday after is shown below

Observed Holidays
New Year's Day - Observed - No Work=MONTH(G56)=DAY(G56)=DATE(year,B56,C56)+CHOOSE(WEEKDAY(DATE(year,B56,C56)),1,0,0,0,0,0,-1)
Juneteenth - Observed - No Work=MONTH(G68)=DAY(G68)=DATE(year,B68,C68)+CHOOSE(WEEKDAY(DATE(year,B68,C68)),1,0,0,0,0,0,-1)
Independence Day - Observed - No Work=MONTH(G69)=DAY(G69)=DATE(year,B69,C69)+CHOOSE(WEEKDAY(DATE(year,B69,C69)),1,0,0,0,0,0,-1)
Veterans Day - Observed - No Work=MONTH(G76)=DAY(G76)=DATE(year,B76,C76)+CHOOSE(WEEKDAY(DATE(year,B76,C76)),1,0,0,0,0,0,-1)
Christmas Day - Observed - No Work=MONTH(G80)=DAY(G80)=DATE(year,B80,C80)+CHOOSE(WEEKDAY(DATE(year,B80,C80)),1,0,0,0,0,0,-1)

These are the dates I am specifically looking for right now, and can reverse engineer for others, I'm just stumbling with these specific dates right now.
 

Excel Facts

How to change case of text in Excel?
Use =UPPER() for upper case, =LOWER() for lower case, and =PROPER() for proper case. PROPER won't capitalize second c in Mccartney
Upvote 0
Hi & welcome to MrExcel.
How about
Excel Formula:
=DATE(year,B56,C56)+CHOOSE(WEEKDAY(DATE(year,B56,C56)),1,0,0,0,0,-1,-2)
 
Upvote 1
Solution

Forum statistics

Threads
1,215,108
Messages
6,123,134
Members
449,098
Latest member
Doanvanhieu

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