Functions can only be used in numeric fields. Currently they have no support for strings, and I don’t really plan to add support for strings - the cost/benefit on that seems prohibitively negative.
There could be a COUNTCHARACTERS(Variable) (COUNTWORDS, COUNTLINES) function that takes a variable name and returns the result. There could also be a CALCULATE(Variable) function that returns the numeric result of the variable after it is calculated.
I’m not sure about processing text tokens. I suppose I could suspend the calculation engine until the matching closing bracket, just like the %Calculate% text token does, and then it would work if and only if the text tokens returned a numeric result (so %ICUDateTime%yyyy% for example).
So all that is relatively straight forward.
What I don’t plan to do is something like “abc” + “def” to produce “abcdef” or anything like that.
Whether a case can be made for anything like COUNTCHARACTERS(“Hello”) or COUNTCHARACTERS("%ICUDateTime%yyyy%"), that I’m not sure. Maybe.
If any of these are added as functions, then they will work in the calculation condition as well as any other numeric field.
Thought you meant there was something called “Set Variable to Action” whatever that would mean. I had tried what you suggested. It actually worked – had I looked at the “old value ➞ new value” in gray in the concatenation action. Instead I was looking at a Display Text Briefly that followed, which didn’t display anything, so I thought there was a failure to concatenate. I still don’t know why the text isn’t displaying.
This is done for the next version. New functions that take text token processed strings and produce either the number of characters, words or lines in the resulting string, or the value of calculating the string
CALCULATE(%ICUDateTime%yyyy%+3) — Process Text Tokens and then calculate
CHARACTERS(%Variable%Text%) — Process Text Tokens and then count characters
WORDS(%Variable%Text%) — Process Text Tokens and then count words
LINES(%Variable%Text%) — Process Text Tokens and then count lines