SD Delete Comment for MT5
This is a script for quick deleting comments left in the upper left corner of the chart. Other objects are not deleted. The script reports about finishing its operation using alerts.
It is useful when there is a text on the chart left by
- a script that checks the result of some operations and displays the information using Comment() function;
- an indicator or EA that doesn't have a function of deleting its own comments (an application under development or downloaded from the Internet).
Some script advantages:
When deleting a comment, it automatically saves it to the trading terminal's log file: *\MQL5\Logs. This may be convenient when deleted data can be then used in comparisons or analyses. After that, you can manually find the text deleted with the script using the Experts folder. The tab contains the filter allowing you to quickly move to the necessary entries in the trading terminal log files. In order to activate the filter:
- move to the "Experts" tab of the trading terminal;
- click the right mouse button to open the menu;
- select "View".
It will be more convenient to use SD Delete Comment for MT5 if you set a hotkey for it or add it to Favorites in the Navigator.
Quick Start Using Keyboard or Favorites in the Navigator:
If the "Navigator" window is not opened in the terminal, then:
- click "View" in the upper menu of МetaTrader 5;
- choose "Navigator" in the list;
- on the "Common" tab navigate to the application (Expert Advisor, indicator, script) that you want to start quickly;
- click on the application name with the right mouse button;
- click "Add to favorites" and/or "Set a hotkey" in the menu.
It's been added for convenience - when you need to view the text of a comment previously deleted by the script in the list of past alert signals or the Experts terminal tab.
In addition, added display of MQL5 program runtime error code if the script cannot perform its functions.
- Now, once it ends working, it shows an alert containing the text that has been deleted.
- If there are no comments on the chart set using "Comment();" or "ChartSetString(chart_ID,CHART_COMMENT,str_value);" functions, the script will display "There is no comment there. Script removed.".