Download MetaTrader 5

Array out of range

To add comments, please log in or register
How to launch your trading signal and become a provider
Waddah
34
Waddah 2016.11.16 11:48 

hi  ,  I need help to fix this code , every time I get this Error : Array Out of range 

This Code is to print  : Pairs   RSI value

                           eg.     EURUSD   33.5 

------------------------------------------------------------------------------ 

 int X_Shift,Y_Shift;

  X_Shift=200;

 Y_Shift=10+Y_Move;


 int sizeRSI=ArraySize(Symbols);

 for(int i=0; i < sizeRSI; i++)

 {

 RSIs[i]=iRSI(Symbols[i],240,24,0,0); //(The EA  stop here)


   CreatePanel("RSI",OBJ_EDIT,DoubleToString(RSIs[i]), X_Shift, Y_Shift,60,25,Blue,White,Black,9,true,false,0,ALIGN_CENTER);  

  Y_Shift+=40; 

 

--------------------------------------------------------------------------------------------------------------------------------------------------------------------- 

 

 

Thanks  

Keith Watford
Moderator
9650
Keith Watford 2016.11.16 12:07  
What is the size of RSIs[]  ?
InvestSoft
8595
Janusz Trojca 2016.11.16 12:10  
I suppose that size of RSIs array is smaller than size of Symbols array and this could cause error.
To add comments, please log in or register