
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
Good day.
What indicator do you want to create an Expert Advisor based on?
Keep records of open charts (more precisely, keep records of not chart numbers, but records of actions: the symbol "such and such", the timeframe "such and such" is already open.
i've been trying but i can't find out how, i'm using a multi symbol and multi timeframe expert advisor so its hard for me to check symbol and timeframe for over 100 charts, is there a easier way ?
The terminal can open a maximum of 100 charts (no more).
So, before applying the chart template, you need to bypass all charts and check: "Is the chart on the" SYMBOL "symbol and on the" TIMEFRAME "timeframe already open"?
An example of traversing all charts can be taken from here: ChartNext.
Final function:
Call example:
The terminal can open a maximum of 100 charts (no more).
So, before applying the chart template, you need to bypass all charts and check: "Is the chart on the" SYMBOL "symbol and on the" TIMEFRAME "timeframe already open"?
An example of traversing all charts can be taken from here: ChartNext.
Final function:
Call example:
I've tried this way, still doesn't work
I don't believe anyone if there is no code and no description of actions :)
You did not show the code - you did not describe your actions - you only hear "it does not work". I do not believe you.An example of working with iCustom - we get the indicator data in the EA [data folder]\MQL5\Indicators\Examples\MACD.mq5
Code: iCustom iMACD value on chart.mq5
The custom MACD indicator is located in the folder:
Remember the rule of working with indicators in MQL5: an indicator handle is created in OnInit. In the future, the indicator handle, using CopyBuffer, is used to receive data from the indicator.
I don't believe anyone if there is no code and no description of actions :)
You did not show the code - you did not describe your actions - you only hear "it does not work". I do not believe you.What would i get by lying ? if it doesn't work, it doesn't work, it's totally fine
Your problem is that you cannot formulate the problem. I'm not a wizard or telepathic - but I made an attempt to read your mind ( # 103 ). If you say "it doesn't work for me" - please put yourself in my place: look from the outside - you didn't say anything, but say that nothing works.
If you want help - describe your problem, show the code, tell us what exactly does not work.
Remove all symbols from the Market Watch
Code: Remove all symbols.mq5
Example: how to get the value of the 'iAO' indicator in an advisor
Code: iAO Get Value.mq5
When working in MQL5, remember the main rule: the indicator handle (in this example, it is the 'handle_iAO' variable) must be created ONLY ONCE and IT IS NECESSARY TO DO IN OnInit ()
The code below shows an example of how to get the indicator handle in the EA and how to access the indicator data in the EA. For example, I additionally placed an indicator on the chart so that you can visually compare the indicator readings and the data obtained in the EA.
Code:
Result:
Pic. 1. iAO Get Value
Pic. 2. iAO Get Value