Main code
In this section of the code,
the specified parameter (mode) decide which function to run(There are three functions)
And,These 3 functions using the REF for returning the value.
The declaring of parameter in function as below:
Each function uses a different way for operating data, but uses the same arrays for returning the computed value.
It's abnormal that MC will execute all 3 functions,
It causes the value in the arrays will be the last function computed instead of varying with each conditional 'if'.
My question is:
How to make the function only execute when the conditional 'if' fulfilled?
The REF do not run 'if' and repeated executed.
- Andrew MultiCharts
- Posts: 1587
- Joined: 11 Oct 2011
- Has thanked: 931 times
- Been thanked: 559 times
Re: The REF do not run 'if' and repeated executed.
Hello L.R,
It works as you expect if all three functions have Function Storage = Simple
It works as you expect if all three functions have Function Storage = Simple