fxea729 :
I would like to ask can EA get the user input from chart? For example, when user draw a square on the chart, the EA will know the position of the square and knows the first bar time and the last bar time.
Thanks
In OnChartEvent you can track events
Creating a graphical object (if CHART_EVENT_OBJECT_CREATE=true for a chart) | CHARTEVENT_OBJECT_CREATE | — | — | Name of a created graphical object |
Changing object properties via the properties dialog | CHARTEVENT_OBJECT_CHANGE | — | — | Name of a changed graphical object |
- after that, using the ChartGet functions, get all the data about the graphic object.
![Documentation on MQL5: Constants, Enumerations and Structures / Chart Constants / Chart Properties Documentation on MQL5: Constants, Enumerations and Structures / Chart Constants / Chart Properties](https://c.mql5.com/36/45/documentation-on-mql5-constants__39.png)
Documentation on MQL5: Constants, Enumerations and Structures / Chart Constants / Chart Properties
- www.mql5.com
Chart Properties - Chart Constants - Constants, Enumerations and Structures - MQL5 Reference - Reference on algorithmic/automated trading language for MetaTrader 5
Thanks, I will try that
![MQL5 - Language of trade strategies built-in the MetaTrader 5 client terminal](https://c.mql5.com/i/registerlandings/logo-2.png)
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
I would like to ask can EA get the user input from chart? For example, when user draw a square on the chart, the EA will know the position of the square and knows the first bar time and the last bar time.
Thanks