How to avoid array out of range ?
I don't know exactly what is going on due to lack of information, but it is very likely that the value of k is going negative and RBuffer1[k] or RBuffer2[k] is experiencing an array out of range error.
You agree to website policy and terms of use
Hello Everyone
How to deal with or handle/avoid the array out of range error here :
I am sure there is something wrong with my logic but cant figure out what exactly , and the indicator works fine on some timeframes but on 2 ,3 timeframes it throws the error array out of range
the highlighted part is where I am receiving the error.