Skip to main content

7.13.7 SPLIT_DT

Function

Split the DT type data into six integer type data outputs, respectively output YEAR, MONTH, DAY, HOUR, MINUTE, SECOND six integer type data

LD graphics

SPLIT_DT

Parameter description

Interface variableDeclarationData typeDescription
DTVar_DtDTDate + Time
YEAROut_PutINTYear
MONTHOut_PutINTMonth
DAYOut_PutINTSomeday
HOUROut_PutINTHour
MINUTEOut_PutINTMinute
SECONDOut_PutINTSecond

Example

  • An LD example is shown in the following animation:

SPLIT_DT_GIF

  • ST example is shown in the following code:
SPLIT_DT(
IN:=IN1,
YEAR=>OUT,
MONTH=>OUT2,
DAY=>OUT3,
HOUR=>OUT4,
MINUTE=>OUT5,
SECOND=>OUT6
);