How do I incorporate moving average array into my ea?

 
Example MA_Array[i]= iMA(Symbol(),0,5... ...i); crosses over MA_Array[a]=iMA(Symbol (),0,21....a);
I receive 'MA_Array' - invalid array access 
                'MA_Array' - invalid array access
[Deleted]  
Kiplangat Ngeno Allan:
Example MA_Array[i]= iMA(Symbol(),0,5... ...i); crosses over MA_Array[a]=iMA(Symbol (),0,21....a);
I receive 'MA_Array' - invalid array access 
                'MA_Array' - invalid array access

Learn to reference the documentation. The iMA function returns a handle, not buffer data.

Documentation on MQL5: Technical Indicators / iMA
Documentation on MQL5: Technical Indicators / iMA
  • www.mql5.com
The function returns the handle of the Moving Average indicator. It has only one buffer. Parameters symbol [in] The symbol name of the security...