Wait for 10 bar not to trade after a trade done.

 

Dear Guys

I made a EA. I want to give a function is that after a trade done by EA. EA wait 10 bar not to trade. After 10 bar EA again trade. How do I give that condition.  

 
dralialadin: after a trade done by EA. EA wait 10 bar not to trade. 
Loop through order history and find the latest OrderCloseTime. if iBarShift of OCT < 10 don't trade.
 
WHRoeder:
Loop through order history and find the latest OrderCloseTime. if iBarShift of OCT < 10 don't trade.


That's it! This advice works for me.

Thank you.