So correctORDER_FILLING_ there maybe FOG to RETURN... I've tried it with MT5 too - the slightest interference in the code during trading and I lost $100 on it, new codes also didn't work on the demo until I added some of my features - maybe it was designed that way ... I don't know what for... I abandoned MT5 a long time ago, although I started with it - it seemed safer and simpler...
chipo: So correctORDER_FILLING_ there maybe FOG to RETURN... I've tried it with MT5 too - the slightest interference in the code during trading and I lost $100 on it, new codes also didn't work on the demo until I added some of my features - maybe it was designed that way ... I don't know what for... I abandoned MT5 a long time ago, although I had started with it - it seemed more reliable and easy to use...
Alexander Bereznyak: all standard EAs are built on the standard library, the library should be corrected
There is no need to edit the standard library - this is the wrong approach. You should just save the EA under a new name and change the code a bit. For example, save Moving Averages.mq5 under a new name Moving Averages1.mq5.
In the header add a description that this EA uses the ORDER_FILLING_RETURN execution policy:
There is no need to edit the standard library - this is the wrong approach. You should just save the EA under a new name and change the code a bit. For example, save Moving Averages.mq5 under a new name Moving Averages1.mq5.
In the header add a description that this EA uses the ORDER_FILLING_RETURN execution policy:
and add one line of code to close and open positions:
Great! Everything works. Thank you for your hard work and explanations!
And here comes the cause:
10030
TRADE_RETCODE_INVALID_FILL
Unsupported balance order execution type specified
It has already been mentioned:
Forum on trading, automated trading systems and testing of trading strategies
not a single advisor works in metatrader 5 any currency pair
sandex, 2015.04.29 12:56
switched to dollars, in-house EA does not work, mine does
order execution type should be ORDER_FILLING_RETURN
And here comes the cause:
10030
TRADE_RETCODE_INVALID_FILL
Unsupported balance order execution type specified
which has already been mentioned:
So correctORDER_FILLING_ there maybe FOG to RETURN... I've tried it with MT5 too - the slightest interference in the code during trading and I lost $100 on it, new codes also didn't work on the demo until I added some of my features - maybe it was designed that way ... I don't know what for... I abandoned MT5 a long time ago, although I had started with it - it seemed more reliable and easy to use...
all standard EAs are built on the standard library, the library should be corrected
There is no need to edit the standard library - this is the wrong approach. You should just save the EA under a new name and change the code a bit. For example, save Moving Averages.mq5 under a new name Moving Averages1.mq5.
In the header add a description that this EA uses the ORDER_FILLING_RETURN execution policy:
and add one line of code into functions of position closing and opening:
There is no need to edit the standard library - this is the wrong approach. You should just save the EA under a new name and change the code a bit. For example, save Moving Averages.mq5 under a new name Moving Averages1.mq5.
In the header add a description that this EA uses the ORDER_FILLING_RETURN execution policy:
and add one line of code to close and open positions: