Attribut: monitoring_encoding
Das Attributpragma ist bei Variablen des Datentyps STRING
und bei Variablen eines Alias-Datentyps des Typs STRING
erlaubt. Das Attribut bewirkt, dass während des Monitorings die Werte der damit gekennzeichneten Variablen im UTF-8-Format dekodiert werden.
Syntax:
{attribute 'monitoring_encoding' := 'UTF8'}
Einfügeort: Oberhalb der Variablendeklaration
Beispiel 280. Beispiel
PROGRAM PLC_PRG VAR {attribute 'monitoring.encoding' := 'UTF8'} strDat : STRING := 'abc'; attribute 'monitoring_encoding' := 'UTF-8'} strVarUtf8: STRING := UTF8#'你好,世界!ÜüÄäÖö'; {attribute 'monitoring_encoding' := 'UTF-8'} str1: STRING := UTF8#'AÄyyy'; {attribute 'monitoring_encoding' := 'UTF-8'} str2: STRING := UTF8#'AÄxxxÜÜÜ'; strVarUtf8_1: STRING := '你好,世界!ÜüÄäÖö'; str1_1: STRING := 'AÄyyy'; str2_1: STRING := 'AÄxxxÜÜÜ'; END_VAR
