What would you do if you have no idea if a date is a workday or not? Well, use the WORKDAY function, an excel formula. Check out the formula;
The generic formula to determine if a given date is a work day or not
….where the “date” is the first date in the column and “holidays” is the range of cells with holiday dates.
The excel formula is straightforward in application. However, it is essential to note that the WORKDAY function works by calculating defined “workdays” dates in the future or past. Therefore, it will automatically exclude any date that is weekend and (optionally) holiday. The function accepts only 3 arguments: start_date, days, and (optionally) holidays.
We are going to look at certain dates and determine if they are work days or not. In this example, we are going to test with the Christmas dates. Check out this example:
From the example, the formula in the highlighted cell (D5) is:
The formula returns TRUE because Friday 21, 2018 is a workday.
Figure 1. Example 1 of WORKDAY Function
In this example, we have (C5-1) for start_date, 1 is the days, and (G7:G8) which holidays’ range. With this formula, the function goes a step back one day, then adds 1 day to the outcome while at the same time taking into account holidays and weekends.
Finally, comparison of the original start_date and the WORKDAY function return is done. If the dates appear the same, like in the above example, then the formula returns TRUE. In case the dates aren’t the same, then the formula returns FALSE. That’s how the function/formula works.