.

Arrow for indicator

#1
Dear Mladen and crew, I trying to do an arrow when the bars of this indicator cross 180 and -180 levels respectively, but dont work maybe the levels are dinamics?
i attached indicator and this is my code, thanks soo much for your help.

double RF(int i)
{
double up = iCustom(NULL,0,"Retracement Finder1",3,i)!=EMPTY_VALUE;
double dn = iCustom(NULL,0,"Retracement Finder1",4,i)!=EMPTY_VALUE;

if(up<-180.0000)
{
return(1);
}
if(dn>180.0000)
{
return(-1);
}

return(0);
}

bool Arrowup(int i)
{
bool up=false;

up = RF(i)==1;

if(up)
{
return true;
}
return false;

}
bool Arrowdn(int i)
{
bool dn=false;

dn = RF(i)==-1;

if(dn)
{
return true;
}
return false;
Attachments
Retracement Finder1.mq4
(4.67 KiB) Downloaded 16 times


Who is online

Users browsing this forum: No registered users and 3 guests