ObjectSetInteger ERROR in MQL5..any advice please?

 

I am trying to create a simple indicator on Mql5 but i get an ERROR when i compile it...

Could anyone help me please?

int OnCalculate(const int rates_total,
                const int prev_calculated,
                const datetime &time[],
                const double &open[],
                const double &high[],
                const double &low[],
                const double &close[],
                const long &tick_volume[],
                const long &volume[],
                const int &spread[])
  {
//---
string label="uparrow";
   
ObjectCreate(0,label,OBJ_ARROW_UP,0,iTime(NULL,Timeframe1,3),iLow(NULL,Timeframe1,3));
ObjectSetInteger(0,label,OBJPROP_COLOR,clrBlue);  

   
   
//--- return value of prev_calculated for next call
   return(rates_total);
  }

This is the message i get when i compile it...


 
Kaloko:

I am trying to create a simple indicator on Mql5 but i get an ERROR when i compile...

Could anyone help me please?

This is the message i get when i compile it...


Try this:

ObjectSetInteger(0,label,OBJPROP_COLOR,clrBlue,0);
 
Mahdi Fatemi:

Try this:

I tried it but i am still getting the same ERROR..!

Reason: