Thank you Honest but that's seems to be not solved...
If anyone can help, thanks.
When you change the timeframe, EA and indicators on the chart are unloaded and then loaded again.
If you want your EA to keep appearance when you change timeframe (or instrument) on the chart, you have to write the code that will save current status of the panel(s) and then restore it on the next start.

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,
Started to learn mql5 coding about 1 month ago, and my goal is to create my own simple ea for trading.
For that I choose to use panels and dialogs :displaying chart's infos and buttons for adding indicators and trade assist.
The idea is to have one main panel with buttons opening 3 sub panels for informations and indicators.
I used the models from the Documentation\Standard Library section and so far I met some issues:
-when chage the timeframe my ea(panel) disappears from the chart; if I put only the main panel it's works..so I believe that the subpanels cause this...
-when hit the xbutton of the subpanel it's removes the ea from the chart and for avoiding this I created an extra button for closing the subpanel,
-one of subpanels has a check box, when checked is calling the ChartIndicatorAdd function for add a customised moving average; if I uncheck the checkbox the indicator is not been removed
How can I solve those issues?
Here is the code: