{"id":12335,"date":"2020-06-01T05:00:47","date_gmt":"2020-06-01T02:00:47","guid":{"rendered":"https:\/\/www.davinci-fx.com\/script-for-opening-market-orders-with-magic-number\/"},"modified":"2021-05-25T20:12:05","modified_gmt":"2021-05-25T17:12:05","slug":"script-for-opening-market-orders-with-magic-number","status":"publish","type":"post","link":"https:\/\/www.davinci-fx.com\/en\/script-for-opening-market-orders-with-magic-number\/","title":{"rendered":"Script for opening market orders with given Magic Number"},"content":{"rendered":"<p>This script is used to make it easier to open a deal with user-set data. The ability to set Magic Number is useful when you need a third-party eA to pick up a manual lye order from a trader, for example, to interfere with the trading of an EA. Each EA uses an individual majuk number, this script will allow any EA to count the user&#8217;s order as his own.<\/p>\n<p>The self-commenting feature will help you find this order from all others right away, especially when there are a lot of trade orders.<\/p>\n<p>The script can also automatically calculate the required trading lot, depending on the risk the user has in percentage and Stop Loss.<\/p>\n<h2 style=\"text-align: center;\"><span style=\"color: #333333; font-size: 18pt;\">Script settings:<\/span><\/h2>\n<table style=\"border-collapse: collapse; width: 100%; height: 252px;\" border=\"1\">\n<tbody>\n<tr style=\"height: 56px;\">\n<td style=\"width: 22.2681%; height: 56px;\">Magic Number<\/td>\n<td style=\"width: 77.7319%; height: 56px;\">The required magic number to open the order. If you put it equal to 0, this order will be considered as open manually.<\/td>\n<\/tr>\n<tr style=\"height: 28px;\">\n<td style=\"width: 22.2681%; height: 28px;\">Order Comment<\/td>\n<td style=\"width: 77.7319%; height: 28px;\">A comment that will be assigned to an open order.<\/td>\n<\/tr>\n<tr style=\"height: 28px;\">\n<td style=\"width: 22.2681%; height: 28px;\">Choose Order Direction<\/td>\n<td style=\"width: 77.7319%; height: 28px;\">Choosing the direction of the order being opened: to buy or sell.<\/td>\n<\/tr>\n<tr style=\"height: 28px;\">\n<td style=\"width: 22.2681%; height: 28px;\">Lot<\/td>\n<td style=\"width: 77.7319%; height: 28px;\">A trading lot for the order to be opened.<\/td>\n<\/tr>\n<tr style=\"height: 28px;\">\n<td style=\"width: 22.2681%; height: 28px;\">Auto Risk<\/td>\n<td style=\"width: 77.7319%; height: 28px;\">At a value of more than 0, the trading lot will be calculated in a given percentage of the risk from the deposit, provided that Stop Loss at the order will be installed.<\/td>\n<\/tr>\n<tr style=\"height: 28px;\">\n<td style=\"width: 22.2681%; height: 28px;\">Slippage<\/td>\n<td style=\"width: 77.7319%; height: 28px;\">Slipping orders in old paragraphs<\/td>\n<\/tr>\n<tr style=\"height: 28px;\">\n<td style=\"width: 22.2681%; height: 28px;\">Take Profit<\/td>\n<td style=\"width: 77.7319%; height: 28px;\">The size of Take Profit in old items<\/td>\n<\/tr>\n<tr style=\"height: 28px;\">\n<td style=\"width: 22.2681%; height: 28px;\">Stop Loss<\/td>\n<td style=\"width: 77.7319%; height: 28px;\">The size of Stop Loss in old items<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h2 style=\"text-align: center;\"><span style=\"color: #333333; font-size: 18pt;\"><strong>An example of how the script works:<\/strong><\/span><\/h2>\n<p>Set a script with these settings:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-11612\" src=\"http:\/\/www.davinci-fx.com\/wp-content\/uploads\/2020\/05\/1-4.png\" alt=\"\" width=\"629\" height=\"389\" srcset=\"https:\/\/www.davinci-fx.com\/wp-content\/uploads\/2020\/05\/1-4.png 629w, https:\/\/www.davinci-fx.com\/wp-content\/uploads\/2020\/05\/1-4-300x186.png 300w, https:\/\/www.davinci-fx.com\/wp-content\/uploads\/2020\/05\/1-4-500x309.png 500w, https:\/\/www.davinci-fx.com\/wp-content\/uploads\/2020\/05\/1-4-230x142.png 230w, https:\/\/www.davinci-fx.com\/wp-content\/uploads\/2020\/05\/1-4-200x124.png 200w\" sizes=\"auto, (max-width: 629px) 100vw, 629px\" \/><\/p>\n<p>Magic number is 1111, comment &#8220;DaVinci FX,&#8221; risk 5 on the deal.<\/p>\n<p><a ref=\"magnificPopup\" href=\"http:\/\/www.davinci-fx.com\/wp-content\/uploads\/2020\/05\/2-5.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter wp-image-11613 size-large\" src=\"http:\/\/www.davinci-fx.com\/wp-content\/uploads\/2020\/05\/2-5-1024x83.png\" alt=\"\" width=\"879\" height=\"71\" srcset=\"https:\/\/www.davinci-fx.com\/wp-content\/uploads\/2020\/05\/2-5-1024x83.png 1024w, https:\/\/www.davinci-fx.com\/wp-content\/uploads\/2020\/05\/2-5-300x24.png 300w, https:\/\/www.davinci-fx.com\/wp-content\/uploads\/2020\/05\/2-5-500x40.png 500w, https:\/\/www.davinci-fx.com\/wp-content\/uploads\/2020\/05\/2-5-1000x81.png 1000w, https:\/\/www.davinci-fx.com\/wp-content\/uploads\/2020\/05\/2-5-230x19.png 230w, https:\/\/www.davinci-fx.com\/wp-content\/uploads\/2020\/05\/2-5-200x16.png 200w, https:\/\/www.davinci-fx.com\/wp-content\/uploads\/2020\/05\/2-5.png 1904w\" sizes=\"auto, (max-width: 879px) 100vw, 879px\" \/><\/a><\/p>\n<p>This order is immediately visible among other orders due to a comment with the name of our team, as well as with a trading lot of 0.79, which at this value Stop Lossa will be approximately 5 losses for the balance of $4,461 if this drawdown is achieved. As you can see, the targets of the warrant were also exposed. Now, if you want to close this order, you can easily do it with our script <strong>Close<\/strong> <strong>all<\/strong> <strong>trading<\/strong> <strong>orders,<\/strong>specifying your installed magician.<\/p>\n<p>It is also convenient to use the script to &#8220;suck&#8221; your orders to other advisers. For example, you have an advisor who opens orders, accompanies the transaction and exits it by filters. You can see that now there is a signal in the market, throw a script with the magic of this EA, as soon as the orders are opened, the installed EA will immediately begin to accompany him in the market and close when he has his signal.<\/p>\n\n<style id=\"kama-click-counter-shortcode\">.kcc_block{ position:relative; width: auto; padding:1em 0 1em; text-align: center; transition:background-color 0.4s; cursor:pointer; }\r\n.button4 {\r\nposition: relative;\r\nwidth: auto;\r\ndisplay: inline-block;\r\nfont-family: Arial,Helvetica,FreeSans,&quot;Liberation Sans&quot;,&quot;Nimbus Sans L&quot;,sans-serif;\r\nfont-size: 1.5em;\r\nfont-weight: 700;\r\ncolor: rgb(245,245,245);\r\ntext-shadow: 0 -1px rgba(0,0,0,.1);\r\ntext-decoration: none;\r\nuser-select: none;\r\npadding: .5em 1em;\r\noutline: none;\r\nborder: none;\r\nborder-radius: 10px;\r\nbackground: #0c9c0d linear-gradient(#82d18d, #0c9c0d);\r\nbox-shadow: inset #72de26 0 -1px 1px, inset 0 1px 1px #98ff98, #3caa3c 0 0 0 1px, rgba(0,0,0,.3) 0 2px 5px;\r\n-webkit-animation: pulsate 1.2s linear infinite;\r\nanimation: pulsate 3s linear infinite;\r\n}\r\n.button4:hover {\r\n-webkit-animation-play-state: paused;\r\nanimation-play-state: paused;\r\ncursor: pointer;\r\n}\r\n.button4:active {\r\ntop: 1px;\r\ncolor: #fff;\r\ntext-shadow: 0 -1px rgba(0,0,0,.3), 0 0 5px #ffd, 0 0 8px #fff;\r\nbox-shadow: 0 -1px 3px rgba(0,0,0,.3), 0 1px 1px #fff, inset 0 1px 2px rgba(0,0,0,.8), inset 0 -1px 0 rgba(0,0,0,.05);\r\n}\r\n@-webkit-keyframes pulsate {\r\n50% {color: #fff; text-shadow: 0 -1px rgba(0,0,0,.3), 0 0 5px #ffd, 0 0 8px #fff;}\r\n}\r\n@keyframes pulsate {\r\n50% {color: #fff; text-shadow: 0 -1px rgba(0,0,0,.3), 0 0 5px #ffd, 0 0 8px #fff;}\r\n}<\/style>\n<div class=\"kcc_block\" title=\"Download\">\r\n        <button class=\"button4 \"><i class=\"fas fa-download\"><\/i> Download for free<\/button>\r\n         \r\n\t\r\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>This script is used to make it easier to open a deal with user-set data. The ability to set Magic Number is useful when you need a third-party eA to pick up a manual lye order from a trader, for example, to interfere with the trading of an EA. Each EA uses an individual majuk&#8230;<\/p>\n","protected":false},"author":1,"featured_media":11611,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[115],"tags":[],"post_folder":[62],"class_list":["post-12335","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-a-set-of-useful-scripts-for-mt4"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v26.7 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Script opens orders with your magic number - DaVinci FX Group<\/title>\n<meta name=\"description\" content=\"By default, manual orders have a magic number equal to zero. This script will allow you to open orders with your magic number and they can participate in the advisor&#039;s trade.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.davinci-fx.com\/en\/magic-number-script\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Script opens orders with your magic number - DaVinci FX Group\" \/>\n<meta property=\"og:description\" content=\"By default, manual orders have a magic number equal to zero. This script will allow you to open orders with your magic number and they can participate in the advisor&#039;s trade.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.davinci-fx.com\/magic-number-script\/\" \/>\n<meta property=\"og:site_name\" content=\"DaVinci FX Group\" \/>\n<meta property=\"article:published_time\" content=\"2020-06-01T02:00:47+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2021-05-25T17:12:05+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.davinci-fx.com\/wp-content\/uploads\/2020\/05\/5-\u0417\u0430\u0441\u0442\u0430\u0432\u043a\u0430-e1598883400455.png\" \/>\n\t<meta property=\"og:image:width\" content=\"1200\" \/>\n\t<meta property=\"og:image:height\" content=\"960\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"admin\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"admin\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"2 minutes\" \/>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Script opens orders with your magic number - DaVinci FX Group","description":"By default, manual orders have a magic number equal to zero. This script will allow you to open orders with your magic number and they can participate in the advisor's trade.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.davinci-fx.com\/en\/magic-number-script\/","og_locale":"en_US","og_type":"article","og_title":"Script opens orders with your magic number - DaVinci FX Group","og_description":"By default, manual orders have a magic number equal to zero. This script will allow you to open orders with your magic number and they can participate in the advisor's trade.","og_url":"https:\/\/www.davinci-fx.com\/magic-number-script\/","og_site_name":"DaVinci FX Group","article_published_time":"2020-06-01T02:00:47+00:00","article_modified_time":"2021-05-25T17:12:05+00:00","og_image":[{"width":1200,"height":960,"url":"https:\/\/www.davinci-fx.com\/wp-content\/uploads\/2020\/05\/5-\u0417\u0430\u0441\u0442\u0430\u0432\u043a\u0430-e1598883400455.png","type":"image\/png"}],"author":"admin","twitter_card":"summary_large_image","twitter_misc":{"Written by":"admin","Est. reading time":"2 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.davinci-fx.com\/magic-number-script\/#article","isPartOf":{"@id":"https:\/\/www.davinci-fx.com\/magic-number-script\/"},"author":{"name":"admin","@id":"https:\/\/www.davinci-fx.com\/#\/schema\/person\/c82159c82394b08fba2ada8d18dcff38"},"headline":"Script for opening market orders with given Magic Number","datePublished":"2020-06-01T02:00:47+00:00","dateModified":"2021-05-25T17:12:05+00:00","mainEntityOfPage":{"@id":"https:\/\/www.davinci-fx.com\/magic-number-script\/"},"wordCount":444,"commentCount":0,"publisher":{"@id":"https:\/\/www.davinci-fx.com\/#organization"},"image":{"@id":"https:\/\/www.davinci-fx.com\/magic-number-script\/#primaryimage"},"thumbnailUrl":"https:\/\/www.davinci-fx.com\/wp-content\/uploads\/2020\/05\/5-\u0417\u0430\u0441\u0442\u0430\u0432\u043a\u0430-e1598883400455.png","articleSection":["Scripts"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.davinci-fx.com\/magic-number-script\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.davinci-fx.com\/magic-number-script\/","url":"https:\/\/www.davinci-fx.com\/magic-number-script\/","name":"Script opens orders with your magic number - DaVinci FX Group","isPartOf":{"@id":"https:\/\/www.davinci-fx.com\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.davinci-fx.com\/magic-number-script\/#primaryimage"},"image":{"@id":"https:\/\/www.davinci-fx.com\/magic-number-script\/#primaryimage"},"thumbnailUrl":"https:\/\/www.davinci-fx.com\/wp-content\/uploads\/2020\/05\/5-\u0417\u0430\u0441\u0442\u0430\u0432\u043a\u0430-e1598883400455.png","datePublished":"2020-06-01T02:00:47+00:00","dateModified":"2021-05-25T17:12:05+00:00","description":"By default, manual orders have a magic number equal to zero. This script will allow you to open orders with your magic number and they can participate in the advisor's trade.","breadcrumb":{"@id":"https:\/\/www.davinci-fx.com\/magic-number-script\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.davinci-fx.com\/magic-number-script\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.davinci-fx.com\/magic-number-script\/#primaryimage","url":"https:\/\/www.davinci-fx.com\/wp-content\/uploads\/2020\/05\/5-\u0417\u0430\u0441\u0442\u0430\u0432\u043a\u0430-e1598883400455.png","contentUrl":"https:\/\/www.davinci-fx.com\/wp-content\/uploads\/2020\/05\/5-\u0417\u0430\u0441\u0442\u0430\u0432\u043a\u0430-e1598883400455.png","width":1200,"height":960,"caption":"5 Saver"},{"@type":"BreadcrumbList","@id":"https:\/\/www.davinci-fx.com\/magic-number-script\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u0413\u043b\u0430\u0432\u043d\u0430\u044f \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430","item":"https:\/\/www.davinci-fx.com\/en\/"},{"@type":"ListItem","position":2,"name":"Script for opening market orders with given Magic Number"}]},{"@type":"WebSite","@id":"https:\/\/www.davinci-fx.com\/#website","url":"https:\/\/www.davinci-fx.com\/","name":"DaVinci FX Group","description":"\u0424\u043e\u0440\u0435\u043a\u0441 \u0421\u043e\u0432\u0435\u0442\u043d\u0438\u043a\u0438, \u0418\u043d\u0434\u0438\u043a\u0430\u0442\u043e\u0440\u044b, \u0421\u043a\u0440\u0438\u043f\u0442\u044b, \u041e\u0431\u0443\u0447\u0435\u043d\u0438\u044f","publisher":{"@id":"https:\/\/www.davinci-fx.com\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.davinci-fx.com\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/www.davinci-fx.com\/#organization","name":"DaVinci FX Group","url":"https:\/\/www.davinci-fx.com\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.davinci-fx.com\/#\/schema\/logo\/image\/","url":"https:\/\/www.davinci-fx.com\/wp-content\/uploads\/2020\/05\/Logo-\u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0435-\u0441-\u043d\u0430\u0434\u043f\u0438\u0441\u044c\u044e-\u043a\u0440\u0443\u043f\u043d\u044b\u0439.png","contentUrl":"https:\/\/www.davinci-fx.com\/wp-content\/uploads\/2020\/05\/Logo-\u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0435-\u0441-\u043d\u0430\u0434\u043f\u0438\u0441\u044c\u044e-\u043a\u0440\u0443\u043f\u043d\u044b\u0439.png","width":800,"height":800,"caption":"DaVinci FX Group"},"image":{"@id":"https:\/\/www.davinci-fx.com\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.instagram.com\/davincifxgroup\/","https:\/\/www.youtube.com\/channel\/UC-rERLLrIiTADzyoYyQ1JOg"]},{"@type":"Person","@id":"https:\/\/www.davinci-fx.com\/#\/schema\/person\/c82159c82394b08fba2ada8d18dcff38","name":"admin","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.davinci-fx.com\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/1e0c72ade8262ff623eeb91910865a86c4923ca6db1ce50997aee96dec89154b?s=96&d=monsterid&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/1e0c72ade8262ff623eeb91910865a86c4923ca6db1ce50997aee96dec89154b?s=96&d=monsterid&r=g","caption":"admin"},"url":"https:\/\/www.davinci-fx.com\/en\/author\/admin\/"}]}},"_links":{"self":[{"href":"https:\/\/www.davinci-fx.com\/en\/wp-json\/wp\/v2\/posts\/12335","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.davinci-fx.com\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.davinci-fx.com\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.davinci-fx.com\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.davinci-fx.com\/en\/wp-json\/wp\/v2\/comments?post=12335"}],"version-history":[{"count":6,"href":"https:\/\/www.davinci-fx.com\/en\/wp-json\/wp\/v2\/posts\/12335\/revisions"}],"predecessor-version":[{"id":16901,"href":"https:\/\/www.davinci-fx.com\/en\/wp-json\/wp\/v2\/posts\/12335\/revisions\/16901"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.davinci-fx.com\/en\/wp-json\/wp\/v2\/media\/11611"}],"wp:attachment":[{"href":"https:\/\/www.davinci-fx.com\/en\/wp-json\/wp\/v2\/media?parent=12335"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.davinci-fx.com\/en\/wp-json\/wp\/v2\/categories?post=12335"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.davinci-fx.com\/en\/wp-json\/wp\/v2\/tags?post=12335"},{"taxonomy":"post_folder","embeddable":true,"href":"https:\/\/www.davinci-fx.com\/en\/wp-json\/wp\/v2\/post_folder?post=12335"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}