Errors, bugs, questions - page 1903
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
just opened the MT4 terminal in that development and was shocked
all the accounts are down - but it's fixable
I lost all the codes from the MetaEditor, and yesterday I failed to synchronize a couple of projects with the repository.
A day's work down the drain.
Can you comment on the situation?
it's the same on the other terminal.
All the codes from the Metadvisor are gone, and I still haven't synced a couple of projects with the repository yesterday.
Most likely not missing.
If the accounts are gone, almost certainly a new folder has been created in app data/roaming for the terminal data, just look in all the folders.
MT4 has started to crash frequently with a wind error (after an update?) - never seen this before, even if there was not enough memory - it just messed up in the calculations. Where to look for the problem?
A question has arisen: how can I find out how many instances of the class there are?
The reason: there is a loop inside the class, inside which you only need to do some calculations if there is only one instance of the class, in other instances you need to skip such calculations to avoid duplicating them and doing unnecessary calculations (they were done in the very first instance of the class and shared - available outside the class)
A question has arisen: how can I find out how many instances of the class there are?
The reason: there is a loop inside the class, inside which you only need to do some calculations if there is only one instance of the class, in other instances you need to skip such calculations to avoid duplicating them and doing unnecessary calculations (they were done in the very first instance of the class and shared - available outside the class)
Describe the static object counter in the class. In constructor - increase, in destructor - decrease.
The reason is this: there is a loop within the class, within which you only need to do some calculations if there is only one instance of the class, in other instances you need to skip such calculations to avoid duplicating them and doing unnecessary calculations (they were done in the very first instance of the class and are shared - available outside the class)
Why not use a reference to a single instance of the class?
And inside - either calculate (when new data appears) or return the finished result.
A question has arisen: how can I find out how many instances of the class there are?
The reason: there is a loop inside the class, inside which you need to do some calculations only if there is only one instance of the class, in other instances you need to skip such calculations to avoid duplicating them and doing unnecessary calculations (they were done in the very first instance of the class and shared - available outside the class)
Even better, all unique calculations should be moved to a separate class and make it a singleton.
Even better is to put all unique calculations into a separate class and make it a singleton.
The calculation is not unique - if there is a single instance of the class then the calculation should be, if there are multiple instances then why duplicate the same calculation in other instances of the same class? It takes up resources.
At the same time, it is not optimal to make one more long cycle in a parent class to calculate the same data (two long cycles), and the child class will not be self-sufficient.
Why not use a reference to a single instance of the class?
And inside - either calculate (when new data appears) or return the finished result.