Format
ValueAt_Sampled(Expr,Time)
Returns
Returns the value of the expression at the specified time.
Inputs
Expr: The expression being evaluated.
Behaviour: Required
Dimension: Collection
Valid data types: Boolean, DateTime, Decimal, Integer, String, Duration, Error, Null
Time: The time at which the expression is to be evaluated. If this argument is an empty collection, the function will also return an empty collection rather than an error.
Behaviour: Required
Dimension: Collection, SingleValue
Valid data types: DateTime, Decimal, Integer, String
Examples
Expression: ValueAt_Sampled({tagname}, Time() - 60)
Result: Value of tagname one minute (60 seconds) ago.
Expression: ValueAt_Sampled({tagname1} + {tagname2}, Time() - 60)
Result: Value of sum of tagname1 and tagname2 one minute ago.
Expression: ValueAt_Sampled({tagname}, ProductionDayStart(Time()))
Result: Value of tagname at the start of the production day.