i have some experience in MQL4 and still learning MQL5 language. I understand most basic code conversion MQL4 to MQL5.
Recently i learn that there is a MQL5 Wizard to create an EA automatically. Tried to make it create a simple EA to open buy if RSI>80 and sell if RSI<20. It works but i have no idea how it open a new trade because it has no OrderOpen Ctrade or OrderSend() Trade Operation Types. It only shows ExtExpert.OnTick();. Currently i only know these 2 methods opening a new trade, still figuring out which one i'm going to explore. Ctrade seems more simple but i feel like it skips many important things but i'll see the difference later.
So the question is: How this code works by opening a BUY and SELL trade? You may also give me an article about it.
You can see and study it in the Expert.mqh file
ah thanks found it. i also find this useful doc: CExpert
one more. is it faster using this CExpert or either Ctrade/OrderSend when we talk about excecution speed and resource spent?

- www.mql5.com
Please consider which section is most appropriate — https://www.mql5.com/en/forum/172166/page6#comment_49114893

- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
i have some experience in MQL4 and still learning MQL5 language. I understand most basic code conversion MQL4 to MQL5.
Recently i learn that there is a MQL5 Wizard to create an EA automatically. Tried to make it create a simple EA to open buy if RSI>80 and sell if RSI<20. It works but i have no idea how it open a new trade because it has no OrderOpen Ctrade or OrderSend() Trade Operation Types. It only shows ExtExpert.OnTick();. Currently i only know these 2 methods opening a new trade, still figuring out which one i'm going to explore. Ctrade seems more simple but i feel like it skips many important things but i'll see the difference later.
So the question is: How this code works by opening a BUY and SELL trade? You may also give me an article about it.