



NOTICE

String manipulation when converting to STRING
or WSTRING
When converting the type to STRING
or WSTRING
, the typed value is left-aligned as a string and truncated if it is too long. Therefore,
declare the return variable for the type conversion operators <>_TO_STRING
and <>_TO_WSTRING
long enough that the string has enough space without any manipulation.
The operands of type DATE
, DATE_AND_TIME
, TIME_OF_DAY
, DT
, or TOD
, which are passed to an operator for a data and time conversion, are converted to
their constant syntax (literal syntax). The generated string contains the keyword
D#
, DT#
or TOD#
and then the size with its data and time unit, as indicated in the IEC 61131-3 specification.
Examples
