One click close - EA MetaTrader 4

The code is used to demonstrate how one can create a button on the chart and assign a function to it.  The code is used to delete all orders after clicking on the button. The deletion takes care of various scenarios and shows error messages. ...

from https://tradingrobots.net/one-click-close-expert-advisor-for-metatrader-4/