How to Learn MQL Programming ?

 

Hello,

I want to develop an Expert Advisor for my trading system, it's not perfect so there will be several modifications along the way before it gives consistent profit. I can easily order that EA and it won't cost me much but the system is not perfect so I want to develop and make it better myself.

I am a C# programmer with 2 year programming experience, I do not have the know how of any other language. I want to learn the MQL4/MQL5 but haven't got any specific information or learning material from search engines. I have found some links about Expert Advisor Builders, what is the builder and how it works I do not know.

You guys are experienced and develop many EAs, please suggest me what is better MQL4 or MQL5 in developing and debugging process and how to learn it. I do not prefer or looking for any shortcuts.

If you have some learning sources please let me know in the reply!

If you want to suggest anything else which I haven't mentioned I would be happy to know and learn from your experience!

Best Regards,

M.Aqib

 

mql4 ~ C

mql5 ~ C++

The best way for me was to study and copy and modify the code workings EAs, indicators and scripts.

For further questions first read the Documentation (see above) and the reference of the editor.

If you have further question you'll be better off searching with google "mt4.." than with metatrader's own search engine.

Finally you can ask questions about coding here..

 

Decide on your users (just you I assume), and your brokers. From your brokers decide your platform - Which ones have MT5 vs MT4. What happens if you change broker?

MQL4 does have some OOP - it's mainly the inputs (quotes, history) and outputs (Orders) that are not OOP. The Orders interface is pretty archaic, but its still OK to work with.

Having said that fairly sure that one day MQ will completely merge MQL4 into MQL5. So if using MQL4 try to write code that will insulate you from changes should you migrate. This is mostly around the inputs and outputs. Maybe have some wrapper classes.

 
Best learning sources (close by ones anyway) are at the top of this window.  On MQL4.com, the tabs labeled documentation and book, and on MQL5.com, docs, codebase, and articles.  If you do not have any interest in programming for MT5, then you can ignore the MQL5.com ideas.
 

Thank you guys for the advice and tips, I'm doing good.

I can't absorb all at once so I'm going very slower.

 
This site has a great MQL5 manual you can see on the Documentation section. I think you will learn a lot there.