Hello Guys,
Bollinger breakout strategy have been around for some time. In an attempt to create a variation of a bollinger breakout strategy I have been able to code the EA attached below. However the following lines of Code just wont work. ALL ATTEMPTS TO SPOT THE ERROR in the code has proved futile .
I will be really grateful if someone could help fix this and tell me where I made the error so that I and others who may make the mistake can learn.
Attached is screen shots and the Faulty Expert Advisor
MANY MANY THANKS
Bollinger breakout strategy have been around for some time. In an attempt to create a variation of a bollinger breakout strategy I have been able to code the EA attached below. However the following lines of Code just wont work. ALL ATTEMPTS TO SPOT THE ERROR in the code has proved futile .
Inserted Code
double MA_Prev=iMA(NULL,0,MaTrendPeriod,MaTrendShift,MODE_LWMA,PRICE_CLOSE,1); if (TradeBar!= iTime(0,0,0)&&CloseB4TradeBar!=Close[1]) //dont closetrade while price is on trade bar neither use close of bar before trade bar to close { if (ExistPositions()==true) { if (Close[1]>MA_Prev) { CloseSell(); Print(Close[1]," > ",MA_Prev); } if (Close[1]<MA_Prev) { CloseBuy(); Print(Close[1]," < ",MA_Prev); } } }
I will be really grateful if someone could help fix this and tell me where I made the error so that I and others who may make the mistake can learn.
Attached is screen shots and the Faulty Expert Advisor
MANY MANY THANKS
Attached File(s)
RemakeGoaway.mq4
9 KB
|
228 downloads