
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
Here is some typical code which prevents an EA from trading until enough bars are available.
start()
{
.....
.....
//Are there enough bars to consider a trade?
if (Bars < 25)
{
Print(" Bars < 25. Waiting for more bars.");
return(0);
}
.....
.....
}
Code like this is seen in some examples and not in others.
While I appreciate that an EA cannot work if there are no bars, I don't understand why or when this would happen.
Thank you in advance.