I tried a script (using the same code) and it works fine, but it still refuses when it's the EA (error 4752 !?)
onewithzachy:
Hi danielthv,
I have MT with MetaQuotes server. Now my EA can't trade but script can. I think MQ wants to run ATC trouble free. That was just my opinion, I didn't check with other broker server.
However I don't understand your retcode 10027, did you click the auto trading button on MT toolbar ?
Thank you for your reply.
if temres is a MqlTradeResult type variable, temres.retcode is what is returned after an Ordersend command is placed.
However, it works again when I tried it this morning (probably Metaquotes did something on their side)
Daniel
Documentation on MQL5: Standard Constants, Enumerations and Structures / Data Structures / Structure of a Trade Request Result
- www.mql5.com
Standard Constants, Enumerations and Structures / Data Structures / Structure of a Trade Request Result - Documentation on MQL5
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
Hello everyone,
When sending a TradeRequest, my EA now always returns the error 4752 (Trading by Expert Advisors prohibited) and the retcode =10027 (Autotrading disabled by client terminal).
Still, the "Options/ExpertAdvisor/Allow Auto Trading" is well checked and the 3 cases of "Disable Auto Trading" are unchecked.
A reboot doesn't help. I don't understand what going on.
Maybe you have an idea ?
Thank you in advance.
Daniel