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

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
New, delete are not used. Class elements are declared at the beginning and I don't recreate them.
Mostly a lot of work is done with arrays.
What aretest-case scripts ?
You make a class and probably (even before) write a bunch of scripts (or one or two scripts and a lot of testing functions) which check that it does exactly what it's supposed to do and that's how it works and that's it's usability.
At the same time it checks for stability, bugs and memory leaks.
You don't have to debug a class on a huge complex with many others like it.
----
If you work a lot with arrays, periodically output the array sizes to the external log and see which one bloats to an unimaginable size while working.
By the way, recursive calls may cause out-of-memory if there are arrays inside. Check that there is no recursion or that it is properly limited.
Please advise, what do I need to learn to exchange data between charts in MT4, as well as between terminals (not via internet)?
Please advise, what do I have to study to learn how to exchange data between charts in mt4, as well as between terminals (not via internet)?
A file can be usedbetween terminals on the same machine via the "Common" folder
If I'm not mistaken, the address is: C:\Users\<....>\AppData\Roaming\MetaQuotes\Terminal\Common\
If between charts, EventChartCustom, terminal global variables, file, winapi.
Between terminals on the same machine, you can use a file in the "Common" folder
If I'm not mistaken, the address is: C:\Users\<....>\AppData\Roaming\MetaQuotes\Terminal\Common\
Turns out it's not all that complicated (I mean, only winapi is complicated)! Thanks ! :)
Line 61, which line is it?
Can't say right now, it's on a VPS, can't access it yet
Is the source on a VPS? You don't have it on your computer? Okay, not interested anymore.
Is the source on a VPS? You don't have it on your computer? OK, not interested anymore.
Okay. (chuckles)
Yeah, I'm just off the computer.
In general, the situation is as follows. There are several "lots" Lots1, Lots2, Lots3, and so on. At each stop the lot changes. I cannot multiply the lot using Martingale, they are all different. I tried to adapt standard functions FindLastLot() and others. It turned out very cumbersome and abnormally worked. That is, for each lot I have prescribed OrderSend and a heap of functions which prevented parallel opening of other orders. Then I decided to try using the while loop and attach to it a switch case but I remembered that it only works with integers. I thought we could use the for loop, but the orders are closed, hence, they have to be searched for in closed positions. But how? I need to write one more loop, i.e., for and while in it? I have only questions... I searched for answers on the forum and on the Internet, too. Everything is banal. All was just Martingale multiplied by two. I have only hope for you, MQL masters. May you advise me in what direction to go?