Hi folks,
i would like to start with an indicator (lets say) every wednesday.
i did it like that, but it isn't working (obviously i am not very experienced in programming in MT4)
------------------------------------------
start()
{
int counted_bars=IndicatorCounted();
if(Bars<=0) return(0);
if(counted_bars<1)
i=Bars-counted_bars-1;
while(i>=0)
{
if(DayOfWeek()>2)
TestBuffer1[i]=iATR("EURUSD",0,1,0);
i--;
}
return(0);
}
------------------------------------------
(its just an example)
where am i wrong?
many thanks!
ron
i would like to start with an indicator (lets say) every wednesday.
i did it like that, but it isn't working (obviously i am not very experienced in programming in MT4)
------------------------------------------
start()
{
int counted_bars=IndicatorCounted();
if(Bars<=0) return(0);
if(counted_bars<1)
i=Bars-counted_bars-1;
while(i>=0)
{
if(DayOfWeek()>2)
TestBuffer1[i]=iATR("EURUSD",0,1,0);
i--;
}
return(0);
}
------------------------------------------
(its just an example)
where am i wrong?
many thanks!
ron