LIMITS PRO SCRIPT FILE conversion from mq4 to mq5 with 1 error

 

hi guys there is one error coming up and i just couldn't clear it, the basic idea here was to covert a script file LIMITS PRO from mq4 to mq5.





 

This cannot work:

#define OrderMagicNumber 9
#define OrderOpenPrice 10
#define OrderSymbol 0
#define OrderModify 13
#define OrderLots 15
#define SELECT_BY_POS 12
#define RefreshRates 1
#define Bid 10
#define Ask 11

You are replacing MT4 function calls and variables with numbers, how should this form a valid MQL 5 script?

You could try it with MT4Orders.mqh. Just follow the link and check the mq5 example script.

https://www.mql5.com/en/code/16006

MT4Orders
MT4Orders
  • www.mql5.com
This library allows to work with the orders in MQL5 (MT5-hedge) in the same way as in MQL4. That is, the order language system (OLS) becomes identical to MQL4. At the same time, it is still possible to use the MQL5 order system in parallel. In particular, the standard MQL5 library will continue to fully operate. It is not necessary to choose...
 
Go here, please.  Regards.
Trading applications for MetaTrader 5 to order
Trading applications for MetaTrader 5 to order
  • www.mql5.com
Hello everyone, I need an Expert Advisor that use SMA 40 low and SMA 40 close and also a Exponential moving average, with few rules to open and close the trades. Thank you very much I will require simple EA that will copy signals from Telegram channels I am currently subscribed at. It will have 3 TP's so i would require it to move stop loss...
 
SunDragon:
...


Forum on trading, automated trading systems and testing trading strategies

When you post code please use the CODE button (Alt-S)!

Use the CODE button


 
Sergey Golubev:



done, can you help now>?
 
SunDragon:
done, can you help now>?
I am not a coder (I can not help sorry).
 
SunDragon:
done, can you help now>?

Where is the code?