{"id":53,"date":"2021-07-20T21:30:24","date_gmt":"2021-07-20T18:30:24","guid":{"rendered":"https:\/\/laboratoryfx.com\/?p=53"},"modified":"2021-07-20T21:30:24","modified_gmt":"2021-07-20T18:30:24","slug":"%d1%84%d1%83%d0%bd%d0%ba%d1%86%d0%b8%d0%b8-%d0%b7%d0%b0-%d0%be%d0%bf%d1%80%d0%b5%d0%b4%d0%bb%d0%b5%d0%bd%d0%b5-%d0%bd%d0%b0-%d0%be%d1%82%d0%b2%d0%b0%d1%80%d1%8f%d0%bd%d0%b5%d1%82%d0%be-%d0%bd%d0%b0","status":"publish","type":"post","link":"https:\/\/laboratoryfx.com\/?p=53","title":{"rendered":"\u0424\u0443\u043d\u043a\u0446\u0438\u0438 \u0437\u0430 \u043e\u043f\u0440\u0435\u0434\u043b\u0435\u043d\u0435 \u043d\u0430 \u043e\u0442\u0432\u0430\u0440\u044f\u043d\u0435\u0442\u043e \u043d\u0430 \u043d\u043e\u0432 \u0431\u0430\u0440"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">\u041f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u0435\u043d\u0438\u0442\u0435 \u043f\u043e-\u0434\u043e\u043b\u0443 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u0442 \u0434\u0430\u043b\u0438 \u0438\u043c\u0430 \u043e\u0442\u0432\u043e\u0440\u0435\u043d \u043d\u043e\u0432 \u0431\u0430\u0440 \u043d\u0430 \u0441\u044a\u043e\u0442\u0432\u0435\u0442\u043d\u0438\u044f \u0442\u0430\u0439\u043c\u0444\u0440\u0435\u0439\u043c \u043d\u0430 \u043a\u043e\u0439\u0442\u043e \u0441\u0430 \u0430\u043a\u0442\u0438\u0432\u0438\u0440\u0430\u043d\u0438, \u0442.\u0435. \u0430\u043a\u043e \u0444\u0443\u043d\u043a\u0446\u0438\u0438\u0442\u0435 \u0440\u0430\u0431\u043e\u0442\u044f\u0442 \u043d\u0430 \u0442\u0430\u0439\u043c\u0444\u0440\u0435\u0439\u043c \u041c5, \u0442\u043e \u0449\u0435 \u0432\u0440\u044a\u0449\u0430\u0442 \u043f\u043e\u043b\u043e\u0436\u0438\u0442\u0435\u043b\u0435\u043d \u043e\u0442\u0433\u043e\u0432\u043e\u0440 \u0437\u0430 \u0432\u0441\u0435\u043a\u0438 \u043e\u0442\u0432\u043e\u0440\u0435\u043d \u043d\u043e\u0432 \u043f\u0435\u0442\u043c\u0438\u043d\u0443\u0442\u0435\u043d \u0431\u0430\u0440.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>\u0424\u0443\u043d\u043a\u0446\u0438\u044f 1<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>bool NewBar()\r\n  {\r\n   static datetime lastbar;\r\n   datetime curbar = Time&#91;0];\r\n   if(lastbar!=curbar)\r\n     {\r\n      lastbar=curbar;\r\n      return (true);\r\n     }\r\n   else\r\n     {\r\n      return(false);\r\n     }\r\n  }<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>\u0424\u0443\u043d\u043a\u0446\u0438\u044f 2<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">static int BARS;\nbool IsNewBar()\n\u00a0\u00a0 {\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0if(BARS!=Bars(_Symbol,_Period))\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0{\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0BARS=Bars(_Symbol,_Period);\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0return(true);\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0}\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0return(false);\n\u00a0\u00a0 }<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>\u0424\u0443\u043d\u043a\u0446\u0438\u044f 3<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">bool IsNewBar() {\n  if (stopper == Time[1])\n  {\n    stopper = Time[0];\n    return true;\n  }\n  else\n  {\n    return false;\n  }\n}<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u0413\u043e\u0440\u043d\u0438\u0442\u0435 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u0432\u044a\u0440\u0448\u0430\u0442 \u0435\u0434\u043d\u0430 \u0438 \u0441\u044a\u0449\u0430 \u0440\u0430\u0431\u043e\u0442\u0430 \u0438 \u0435 \u0432\u044a\u043f\u0440\u043e\u0441 \u043d\u0430 \u043f\u0440\u0435\u0434\u043f\u043e\u0447\u0438\u0442\u0430\u043d\u0438\u0435 \u043a\u043e\u044f \u0434\u0430 \u043f\u043e\u043b\u0437\u0432\u0430\u0442\u0435<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u041f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u0435\u043d\u0438\u0442\u0435 \u043f\u043e-\u0434\u043e\u043b\u0443 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u0442 \u0434\u0430\u043b\u0438 \u0438\u043c\u0430 \u043e\u0442\u0432\u043e\u0440\u0435\u043d \u043d\u043e\u0432 \u0431\u0430\u0440 \u043d\u0430 \u0441\u044a\u043e\u0442\u0432\u0435\u0442\u043d\u0438\u044f \u0442\u0430\u0439\u043c\u0444\u0440\u0435\u0439\u043c \u043d\u0430 \u043a\u043e\u0439\u0442\u043e \u0441\u0430 \u0430\u043a\u0442\u0438\u0432\u0438\u0440\u0430\u043d\u0438, \u0442.\u0435. \u0430\u043a\u043e \u0444\u0443\u043d\u043a\u0446\u0438\u0438\u0442\u0435 \u0440\u0430\u0431\u043e\u0442\u044f\u0442 \u043d\u0430 \u0442\u0430\u0439\u043c\u0444\u0440\u0435\u0439\u043c \u041c5, \u0442\u043e \u0449\u0435 \u0432\u0440\u044a\u0449\u0430\u0442 \u043f\u043e\u043b\u043e\u0436\u0438\u0442\u0435\u043b\u0435\u043d \u043e\u0442\u0433\u043e\u0432\u043e\u0440 \u0437\u0430 \u0432\u0441\u0435\u043a\u0438 \u043e\u0442\u0432\u043e\u0440\u0435\u043d \u043d\u043e\u0432 \u043f\u0435\u0442\u043c\u0438\u043d\u0443\u0442\u0435\u043d \u0431\u0430\u0440. \u0424\u0443\u043d\u043a\u0446\u0438\u044f 1 \u0424\u0443\u043d\u043a\u0446\u0438\u044f 2 static int BARS; bool IsNewBar() \u00a0\u00a0 { \u00a0\u00a0\u00a0\u00a0\u00a0\u00a0if(BARS!=Bars(_Symbol,_Period)) \u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0{ \u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0BARS=Bars(_Symbol,_Period); \u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0return(true); \u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0} \u00a0\u00a0\u00a0\u00a0\u00a0\u00a0return(false); \u00a0\u00a0 } \u0424\u0443\u043d\u043a\u0446\u0438\u044f 3&hellip; <\/p>\n<p><a class=\"moretag\" href=\"https:\/\/laboratoryfx.com\/?p=53\">\u041f\u0440\u043e\u0447\u0435\u0442\u0438 \u0446\u044f\u043b\u0430\u0442\u0430 \u0441\u0442\u0430\u0442\u0438\u044f<\/a><\/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,9],"tags":[],"class_list":["post-53","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\/53","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=53"}],"version-history":[{"count":1,"href":"https:\/\/laboratoryfx.com\/index.php?rest_route=\/wp\/v2\/posts\/53\/revisions"}],"predecessor-version":[{"id":54,"href":"https:\/\/laboratoryfx.com\/index.php?rest_route=\/wp\/v2\/posts\/53\/revisions\/54"}],"wp:attachment":[{"href":"https:\/\/laboratoryfx.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=53"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/laboratoryfx.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=53"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/laboratoryfx.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=53"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}