Add EA's indicator on chart

 
#include <Charts\Chart.mqh>
   CChart grafic;
 
int average_handle;

//--- input parametrs
input ENUM_TIMEFRAMES   InpTimeFrame=PERIOD_H1; // Timeframe 
input ENUM_MA_METHOD    InpMethod=MODE_SMA;     // Method
input int               InpPeriod=20;           // Period
input int               InpShift=0;             // Shift

void OnInit()
{
   average_handle = iMA(Symbol(),InpTimeFrame,InpPeriod,InpShift,InpMethod,PRICE_CLOSE);
   if (average_handle<0) Print("Error ",GetLastError(),"in creation of indicator");

   grafic.IndicatorAdd(0,average_handle);
}  

void OnDeinit(const int reason) 
{
   IndicatorRelease(average_handle);
}

Hello,

I'm trying to add a SMA (20)  from 1 hour chart to a 5 minutes chart. 

Tried to use the function IndicatorAdd but it didn't work...

Any advices?