Note this only works in TimeWorks Plus. What the script does is confirms that the day it is on is the day before the holiday OR the day after and so we can then script off of this based on its findings:
- To do something on the day after a holiday:
reportingdate.isholiday(reportingdate.date - 1)
- To do something on the day before a holiday:
reportingdate.isholiday(reportingdate.date + 1)
You could then verify if it is this day using something like for the day before a holiday:
if (reportingdate.isholiday(reportingdate.date - 1) = 1){ category = "Holiday"; } | |