Try the attached. Simply put into the EA file and attach to the chart/trade in you wish to close everything. Demo it. Best regards