FB_CalcFederalHolidaysUS

FB_CalcFederalHolidaysUS 1:

US federal holidays for the current year are calculated based on the date entered. A boolean output indicates whether the entered date matches one of the calculated holidays. To ensure international readability the function block was translated into English. The parameters have the following meaning:

English name

German name

NewYears Day

Neujahr

Martin Luther King "JR" Day

Martin Luther King Tag

Presidents Day

Tag der Präsidenten

Memorial Day

Gedenktag

Independence Day

Unabhängigkeitstag

Labor Day

Labor Day

Columbus Day

Kolumbus-Tag

Veterans Day

Veteranentag

Thanksgiving Day

Erntedank

Christmas Day

Weihnachtstag

VAR_INPUT

dCurrentDate      : DATE;

dCurrentDate: current date.

VAR_OUTPUT

dNewYearsDay           : DATE;
dMartinLutherKingJrDay : DATE;
dPresidentsDay         : DATE;
dMemorialDay           : DATE;
dIndependenceDay       : DATE;
dLaborDay              : DATE;
dColumbusDay           : DATE;
dVeteransDay           : DATE;
dThanksgivingDay       : DATE;
dChristmasDay          : DATE;
dNewYearsDay           : BOOL;
dMartinLutherKingJrDay : BOOL;
dPresidentsDay         : BOOL;
dMemorialDay           : BOOL;
dIndependenceDay       : BOOL;
dLaborDay              : BOOL;
dColumbusDay           : BOOL;
dVeteransDay           : BOOL;
dThanksgivingDay       : BOOL;
dChristmasDay          : BOOL;;

dxxxxxx: Date of the respective holiday.

bxxxxxx: Boolean statement indicating whether today is the respective holiday.

Requirements

Development environment

Required PLC library

TwinCAT from v3.1.4020.32

Tc2_BABasic from v3.1.0.0