As I can request a password from the user so that he can remove the EA from the meta trader, I tried simply putting a return; in the OnDeinit event but it didn't work, AE disappeared from the screen
- Questions: to start with MetaTrader and forex
- print a counting number over candle max price
- Get in touch with developers using Service Desk!
Your topic has been moved to the section: Expert Advisors and Automated Trading — Please consider which section is most appropriate — https://www.mql5.com/en/forum/172166/page6#comment_49114893
Murilo Junqueira: As I can request a password from the user so that he can remove the EA from the meta trader, I tried simply putting a return; in the OnDeinit event but it didn't work, EA disappeared from the screen
You can't impede a user from being able to remove an EA from the chart (or any MQL program for that matter).
It would be a security risk if the MetaTrader application allowed that possibility.
Murilo Junqueira: As I can request a password from the user so that he can remove the EA from the meta trader, I tried simply putting a return; in the OnDeinit event but it didn't work, AE disappeared from the screen
You could try (don't know if this works) to open a new chart and apply a template, loading the EA again, inside the OnDeinit().
Murilo Junqueira: As I can request a password from the user so that he can remove the EA from the meta trader, I tried simply putting a return; in the OnDeinit event but it didn't work, AE disappeared from the screen
Doesn't OnDeinit run when the EA is removed from the chart or when the application is closed?
![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