{"id":57,"date":"2021-07-21T23:09:10","date_gmt":"2021-07-21T20:09:10","guid":{"rendered":"https:\/\/laboratoryfx.com\/?p=57"},"modified":"2021-07-21T23:09:10","modified_gmt":"2021-07-21T20:09:10","slug":"%d1%81%d0%ba%d1%80%d0%b8%d0%bf%d1%82-%d0%b7%d0%b0-%d0%b7%d0%b0%d1%82%d0%b2%d0%b0%d1%80%d1%8f%d0%bd%d0%b5-%d0%bd%d0%b0-%d0%b2%d1%81%d0%b8%d1%87%d0%ba%d0%b8-%d0%b0%d0%ba%d1%82%d0%b8%d0%b2%d0%bd%d0%b8","status":"publish","type":"post","link":"https:\/\/laboratoryfx.com\/?p=57","title":{"rendered":"\u0421\u043a\u0440\u0438\u043f\u0442 \u0437\u0430 \u0437\u0430\u0442\u0432\u0430\u0440\u044f\u043d\u0435 \u043d\u0430 \u0432\u0441\u0438\u0447\u043a\u0438 \u0430\u043a\u0442\u0438\u0432\u043d\u0438 \u0441\u0434\u0435\u043b\u043a\u0438"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">\u041f\u0440\u0438 \u0441\u0442\u0430\u0440\u0442\u0438\u0440\u0430\u043d\u0435\u0442\u043e \u0441\u0438 \u0442\u043e\u0437\u0438 \u0441\u043a\u0440\u0438\u043f\u0442 \u0437\u0430\u0442\u0432\u0430\u0440\u044f \u0432\u0441\u0438\u0447\u043a\u0438 \u043e\u0442\u0432\u043e\u0440\u0435\u043d\u0438 \u0441\u0434\u0435\u043b\u043a\u0438 \u043d\u0430 \u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0430\u0442\u0430.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>\/\/+------------------------------------------------------------------+\r\n#property strict\r\n\r\n#include &lt;stdlib.mqh>\r\n#include &lt;stderror.mqh>\r\n\/\/\r\n\/\/\u0421\u043a\u0440\u0438\u043f\u0442 \u0437\u0430 \u0437\u0430\u0442\u0432\u0430\u0440\u044f\u043d\u0435 \u043d\u0430 \u0432\u0441\u0438\u0447\u043a\u0438 \u0441\u0434\u0435\u043b\u043a\u0438\r\n\/\/\r\nvoid OnStart()\r\n  {\r\n   for(int x=OrdersTotal()-1;x>=0;x--)\r\n     {\r\n      if(!OrderSelect(x,SELECT_BY_POS,MODE_TRADES)) continue;\r\n      if(OrderType()==OP_BUY || OrderType()==OP_SELL)\r\n        {\r\n         if(!OrderClose(OrderTicket(),OrderLots(),OrderClosePrice(),3,clrRed)){ Alert(ErrorDescription(GetLastError())); }\r\n         else Alert(\"All Closed\");\r\n        }\r\n     }\r\n  }\r\n\/\/+------------------------------------------------------------------+\r\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u0421\u043a\u0440\u0438\u043f\u0442\u044a\u0442 \u0441\u0435 \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u044f \u0432\u044a\u0432 \u0432\u0438\u0434\u0430 \u0432 \u043a\u043e\u0439\u0442\u043e \u0435 \u0438 \u043e\u0442\u0433\u043e\u0432\u043e\u0440\u043d\u043e\u0441\u0442\u0430 \u0437\u0430 \u0438\u0437\u043f\u043e\u043b\u0437\u0432\u0430\u043d\u0435\u0442\u043e \u043c\u0443 \u0435 \u0438\u0437\u0446\u044f\u043b\u043e \u0437\u0430 \u0441\u043c\u0435\u0442\u043a\u0430 \u043d\u0430 \u043f\u043e\u0442\u0440\u0435\u0431\u0438\u0442\u0435\u043b\u044f.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u041f\u0440\u0438 \u0441\u0442\u0430\u0440\u0442\u0438\u0440\u0430\u043d\u0435\u0442\u043e \u0441\u0438 \u0442\u043e\u0437\u0438 \u0441\u043a\u0440\u0438\u043f\u0442 \u0437\u0430\u0442\u0432\u0430\u0440\u044f \u0432\u0441\u0438\u0447\u043a\u0438 \u043e\u0442\u0432\u043e\u0440\u0435\u043d\u0438 \u0441\u0434\u0435\u043b\u043a\u0438 \u043d\u0430 \u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0430\u0442\u0430. \u0421\u043a\u0440\u0438\u043f\u0442\u044a\u0442 \u0441\u0435 \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u044f \u0432\u044a\u0432 \u0432\u0438\u0434\u0430 \u0432 \u043a\u043e\u0439\u0442\u043e \u0435 \u0438 \u043e\u0442\u0433\u043e\u0432\u043e\u0440\u043d\u043e\u0441\u0442\u0430 \u0437\u0430 \u0438\u0437\u043f\u043e\u043b\u0437\u0432\u0430\u043d\u0435\u0442\u043e \u043c\u0443 \u0435 \u0438\u0437\u0446\u044f\u043b\u043e \u0437\u0430 \u0441\u043c\u0435\u0442\u043a\u0430 \u043d\u0430 \u043f\u043e\u0442\u0440\u0435\u0431\u0438\u0442\u0435\u043b\u044f.<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[6,8,10],"tags":[],"class_list":["post-57","post","type-post","status-publish","format-standard","hentry","category-forex","category-forex-mql4","category-mql4--"],"_links":{"self":[{"href":"https:\/\/laboratoryfx.com\/index.php?rest_route=\/wp\/v2\/posts\/57","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/laboratoryfx.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/laboratoryfx.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/laboratoryfx.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/laboratoryfx.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=57"}],"version-history":[{"count":1,"href":"https:\/\/laboratoryfx.com\/index.php?rest_route=\/wp\/v2\/posts\/57\/revisions"}],"predecessor-version":[{"id":58,"href":"https:\/\/laboratoryfx.com\/index.php?rest_route=\/wp\/v2\/posts\/57\/revisions\/58"}],"wp:attachment":[{"href":"https:\/\/laboratoryfx.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=57"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/laboratoryfx.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=57"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/laboratoryfx.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=57"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}