SD Delete Comment
This script is intended for deleting comments left in the upper left corner of the chart.
It will be useful when there is a text in the upper left corner of the chart left by some programs using the function Comment(). For example:
- Scripts that inform about their current activity.
- Indicators or Expert Advisor that are being improved or downloaded from the Internet.
The script will quickly delete the comment, report about it using an alert and then stop working. SD Delete Comment does not delete any other objects.
Some script advantages:
When deleting a comment, it automatically saves it to the trading terminal's log file: *\MQL4\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".
You can assign hotkeys for SD Delete Comment or add the utility to the Favorites tab in the "Navigator" window.
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 4;
- 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 MQL4 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.".