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

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
string AUDUSD = "AUDUSD";
At least like this.
That's it!!! That's how it was for me))), erased and forgotten))
Thank you so much!!! Peace in your home!
Expert Advisor, script, indicator are not accessed, but work in the current window. And global variables of different windows/charts do not overlap. Therefore, it should work)
string AUDUSD; // This is a text variable, besides being initially empty, i.e. equal to ""
(Symbol() == AUDUSD) // this string has nothing to do with variable AUDUSD.
But the order opening criteria should not be the same for different instruments/windows. If they are the same, it will indeed open in all windows.
Thank you!
I implemented the logic so that the Expert Advisor would not get the signal to open orders when they open in several windows and would understand that the buy signal was given for such a symbol so the EA would not interfere with others.
There it is!!! That's how it was for me))), erased and forgotten))
Thank you so much!!! Peace into your home!
Or like this on a global variable level
Or like this on global variable level
Actually it is cool)) Now the robot gets a signal and opens orders on different pairs in several windows at once))
Thanks again!
The problem is not in the values of the variable in my opinion. I just have in my code uulsovii recalculation at the occurrence of a new hour. and it turns out that the current symbol new bar appears and calculated the value of bar = 1, but the signal symbol is a new bar has not yet been formed or what is the value for a bar = 2
The problem is solved easily - I just tracked the start of a new bar by the signal symbol
Please advise.
Please show me in the code what exactly you are interested in
Please advise.
Are you referring to a range of values?
Show the code exactly what you are interested in
Do you mean a range of values?
No, for example pass case 1 first, then case 2, etc.
cases execute the opening of orders