mt5dev:
Hello,
If someone could tell me how to store arrays externally / globally I would appreciate it. At the moment I have an array that is written to in the OnCalculate section, but I can't see how to save the results from tick to tick. It is declared outside of the functions with the input variables ex -
then in the main function I'm trying to write to it in a loop ex -
Hi mt5dev,
I don't think any global declared array will lose it's values unless it's property windows gets opened. However you may want to try FileWriteArray() and FileReadArray()
:D
Thanks, filewrite should work.

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
Hello,
If someone could tell me how to store arrays externally / globally I would appreciate it. At the moment I have an array that is written to in the OnCalculate section, but I can't see how to save the results from tick to tick. It is declared outside of the functions with the input variables ex -
then in the main function I'm trying to write to it in a loop ex -