-
Please edit your (original) post and use the CODE button (Alt-S)! (For large amounts of code, attach it.)
General rules and best pratices of the Forum. - General - MQL5 programming forum (2019.05.06)
Messages Editor -
MqlTradeRequest req/*= {0}*/;
The code below that, initializes the structure.
Robert Raleigh:
Please insert the code correctly: when editing a message, press the button and paste your code into the pop-up window.

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
I'm trying to compile a program written by someone else, and I'm getting an error. I'm showing in the code section the part of the code that's giving me a problem, a section that's designed to execute a buy.
The line that's giving me a problem, per the compiler, is:
MqlTradeRequest req= {0};
And the error being reported is:
cannot convert 0 to enum 'ENUM_TRADE_REQUEST_ACTIONS' MultipleOrdersEA MT5 Rev 1.4.mq5 517 29
Here's the relevant code (I tried using the Code control but I'm apparently not understanding how that works, because the code appears but the rest of the message disappears):