for(int i=OrdersTotal()-1 ; i>=0 ; i-- )
for(int Ordercount=0; Ordercount<=total; Ordercount++ )
to
for(int Ordercount=0; Ordercount<total; Ordercount++ )
although that doesn't affect the result
if (OrderCloseTime()==0........ //Not necessary as you are checking open orders if (OrderCloseTime()>0){ShortOrder--;} Again, you are checking open orders - No point to this check.
Count the long/short orders in your loop. Do not open another is there is already 1 open.
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
What can I do? The EA opens an endless Amount of Orders ( and shows "error 1"& "error 130") (important -> MT4)
Also interesting: Only 20 Buy Orders ...