Hi!!
Anybody can help me??
In an EA I need that, after a win...or a loss..the EA have to not re-enter in the trade if we are on the same bar....
is this correct??? Is it wrong?? There is a better way to do it??
Thaks!!!!!
int BarsCount = 0;
void start()
{
if(Bars<100 || IsTradeAllowed()==false) return;
{
if (Bars > BarsCount)
if(CalculateCurrentOrders(Symbol())==0) CheckForOpen();
else CheckForClose();
BarsCount = Bars;
}
return(0);
}
Anybody can help me??
In an EA I need that, after a win...or a loss..the EA have to not re-enter in the trade if we are on the same bar....
is this correct??? Is it wrong?? There is a better way to do it??
Thaks!!!!!
int BarsCount = 0;
void start()
{
if(Bars<100 || IsTradeAllowed()==false) return;
{
if (Bars > BarsCount)
if(CalculateCurrentOrders(Symbol())==0) CheckForOpen();
else CheckForClose();
BarsCount = Bars;
}
return(0);
}
Market is like a puzzle, YOU have to fit the pieces!!