QUESTION IN PROGRAMMING

 

Hello,

---

MT4, EAs Programming 

Just I am wondering while using the ZigZag indicator by calling the iCustom() function as below:

void OnTick()
  {
//---
   double zz0=iCustom(NULL,0,"ZigZag",12,5,3,0,0);
  }

 

it is mostly giving this Alert/Error:

Array out of range: ZigZag.mq4

 

I am using this code, and it's work.


Files:
CheckEA.mq4  2 kb
 
Biantoro Kunarto:

I am using this code, and it's work.


but it is mostly coming in the back test
 
Mohammad Soubra:
but it is mostly coming in the back test

In strategy tester, this EA also work :


 

Forum on trading, automated trading systems and testing trading strategies

Something Interesting

Sergey Golubev, 2016.01.27 12:41

Just some example about how to solve An array is out of range issue (I personally had this issue few times so it may be good to read the thread about how we can solve this our error during the coding for example).

Reason: