属性:monitoring_encoding
属性プラグマは、次のデータ型の変数に使用できます。 STRING
type のエイリアス データ型の変数の場合 STRING
。この属性には、監視中に UTF-8 形式でデコードされるように変数の値がマークされるという効果があります。
構文:
{attribute 'monitoring_encoding' := 'UTF8'}
挿入場所:変数宣言の上
例 280. 例
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
