so the inputs in to my function are the tag values for 5min and 10min tags. I have also tried this without the “” but I get the following error
Last Error Cause com.inductiveautomation.ignition.common.expressions.ExpressionException: Error parsing script for runScript() expression: SyntaxError: ("no viable alternative at input '.'", ('<expression:runScript>', 1, 44, '__RESULT = project.rateOfChange.getChange({[.]5min},{[.]10min})\n'))
ERROR\n'))
ERROR
I noticed you posted in the v7.7 forum, so I didn’t mention the new features of runScript available in v7.8. But you might consider using objectScript() instead, from the Simulation Aids module, if you need more flexibility.
I’ve tried to use runScript in an expression tag part of a UDT also contained in another UDT but haven’t been able to make it work. I’ve even simplified the script so that it just returned a UDT tag with the same result. Any ideas will be welcome.
I wouldn't expect runScript to be much help in tag expressions. objectScript() might be more helpful, but you'll have to share the details. I only use UDTs to automate tag construction, not in bindings or expressions, so I'm not sure what underlying java types would be needed to return a UDT from a script expression.