Any questions from newcomers on MQL4 and MQL5, help and discussion on algorithms and codes - page 1744

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
Help for the pros, it's quicker to ask, namely to hire a tutor so to speak. believe me, it's cheaper and quicker.
but you need an enthusiastic professional to tutor, not just a deep pro, you need to explain the base correctly and that's it. the other 10k pages. heterogeneous information....Thanks for the advice!
Can you tell me which is better:
(my question is mostly about code optimization and any prospects and pitfalls)Write everything in one OnTick block or separate it by function? That is, to have only function calls in OnTick
any type can be written to and read back from double via union.
Function calls are more correct.
Only functions should be logically complete and understandable, so that you can understand the logic of OnTick from the code.
Give me the file here. This is something new, I haven't heard that yet.
Rename any *.mq4 file to any extension and try to compile it, it won't work, the compiler will try to compile it as if it were MT5.
Whatever I wrote there inside file, like(
does not work until I rename the file back to *.mq4.
How to bypass it, may someone from the pros know?
Function calls are more correct.
Only the functions should be logically complete and understandable, so that you can understand the logic of the operation in OnTick from the code.
Rename any *.mq4 file to any extension and try to compile it, it won't work, the compiler will try to compile it as if it were MT5.
Whatever I wrote there inside file, like(
does not work until I rename the file back to *.mq4.
How do I get around it, can someone from the pros know?
It doesn't compile at all!
Throw the file. you can remove all the functions inside
Rename any *.mq4 file
include1.mqh:
script1.mq4 and script1.mq5:
Got it, that's the problem:
there is no such thing in the language now.