I have a load script and I'm trying to do the following variable:
set vTest = if('$(dialMode)'='Month',sum(Comps.SpendDollers));
When I run this script and look in my "Variable Overview" I can see that it's coming out to:
if('Week'='Month',sum(Comps.SpendDollers))
Could someone explain to me how I get the variable "dialMode" to evaluate when I use the variable in my document, and not when the Load Script is ran?
I hope I've made myself clear, please let me know if not.
The dollar expansion is unnecessary, but you do need some inverted commas (") and an equals sign to make the script place the text into the variable as an expression not just a string.
Surely the variable can be calculated outside of the vTest variable you only need the value of the expression not the expression. What I did even handled spaces in dialMode.