Please ensure Javascript is enabled for purposes of website accessibility
Powered by Zoomin Software. For more details please contactZoomin

AVEVA™ InTouch HMI

HTGetTimeStringAtScooter() 函数

  • Last UpdatedMar 21, 2018
  • 1 minute read

HTGetTimeStringAtScooter() 函数为指定的指示器位置上的样本返回一个包含日期/时间的字符串。

类别

历史

语法

MessageResult=HTGetTimeStringAtScooter(Hist_Tag, UpdateCount, ScootNum, ScootLoc, Format_Text);

参数

Hist_Tag

指定了趋势的名称的“历史趋势”标记。

UpdateCount

代表趋势的 .UpdateCount 点域的整数。

ScootNum

代表左指示器或右指示器的整数:
1 = 左指示器
2 = 右指示器

ScootLoc

代表趋势中 .ScooterPosRight 或 .ScooterPosLeft 位置上的值的实数。

Format_Text

指定要使用的日期/时间格式的字符串。以下是可以接受的 Format_Text 字符串:

"Date"、"Time"、"DateTime"、"DOWShort"(例如 Wed)以及 "DOWLong"(例如 Wednesday)。

附注

指定给 UpdateCount、ScootNum、及 ScootLoc 参数的值所发生的任何变化都会导致对该表达式重新求值。这确保了在检索新的数据或移动指示器之后会对表达式重新进行求值。字符串的格式确定了返回值的内容。

示例

以下语句检索 Trend1 趋势右指示器当前位置上的值的日期与时间。该值按照“Time”格式存储在 NewRightTimeString 消息标记中。

NewRightTimeString=HTGetTimeStringAtScooter ("Trend1",Trend1.UpdateCount,2, Trend1.ScooterPosRight,"Time");