<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
	<title type="html"><![CDATA[Forex Software — Custom order comment]]></title>
	<link rel="self" href="https://forexsb.com/forum/feed/atom/topic/6584/" />
	<updated>2017-04-06T17:44:38Z</updated>
	<generator>PunBB</generator>
	<id>https://forexsb.com/forum/topic/6584/custom-order-comment/</id>
		<entry>
			<title type="html"><![CDATA[Re: Custom order comment]]></title>
			<link rel="alternate" href="https://forexsb.com/forum/post/42723/#p42723" />
			<content type="html"><![CDATA[<p>I have tried both variations and they work fine.<br />And if I do not change anything now in the updated version the Magic Number is shown.<br />Thank you very much.<br /><span class="postimg"><img src="http://up.picr.de/28820377uf.jpg" alt="http://up.picr.de/28820377uf.jpg" /></span></p>]]></content>
			<author>
				<name><![CDATA[bru1]]></name>
				<uri>https://forexsb.com/forum/user/8921/</uri>
			</author>
			<updated>2017-04-06T17:44:38Z</updated>
			<id>https://forexsb.com/forum/post/42723/#p42723</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: Custom order comment]]></title>
			<link rel="alternate" href="https://forexsb.com/forum/post/42714/#p42714" />
			<content type="html"><![CDATA[<p>You have to expert your EA again because I updated the code just before writing my previous posts.<br />Then you have to apply the shown changes.</p>]]></content>
			<author>
				<name><![CDATA[Popov]]></name>
				<uri>https://forexsb.com/forum/user/2/</uri>
			</author>
			<updated>2017-04-06T10:04:24Z</updated>
			<id>https://forexsb.com/forum/post/42714/#p42714</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: Custom order comment]]></title>
			<link rel="alternate" href="https://forexsb.com/forum/post/42711/#p42711" />
			<content type="html"><![CDATA[<p>Hello,<br />1. I managed to create the field in the expert input tab, tha is o.k.<br />But it still does not show in the comment (Kommentar)-field when running in MT4.<br />(Only as long as I put the cursor over the empty field, it shows the order number and the EA-ID)<br /><span class="postimg"><img src="http://up.picr.de/28816229ky.jpg" alt="http://up.picr.de/28816229ky.jpg" /></span><br />2. I do not know how to modify (Variant 1 or 2) the &quot;OpenPosition&quot; because in my EA-Studio created EA it looks completely different to the example in your suggestion.<br /><span class="postimg"><img src="http://up.picr.de/28816230ng.jpg" alt="http://up.picr.de/28816230ng.jpg" /></span><br />3. In the EA&#039;s created with FSB I found only one &quot;Order_Comment&quot; line, but there it works and is shown in the Kommentar-line.<br /><span class="postimg"><img src="http://up.picr.de/28816232ae.jpg" alt="http://up.picr.de/28816232ae.jpg" /></span><br />Do you have an idea what I am miss, maybe it is not as easy as I thought</p>]]></content>
			<author>
				<name><![CDATA[bru1]]></name>
				<uri>https://forexsb.com/forum/user/8921/</uri>
			</author>
			<updated>2017-04-06T09:14:32Z</updated>
			<id>https://forexsb.com/forum/post/42711/#p42711</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: Custom order comment]]></title>
			<link rel="alternate" href="https://forexsb.com/forum/post/42686/#p42686" />
			<content type="html"><![CDATA[<p>Thank you very much, I will try and report</p>]]></content>
			<author>
				<name><![CDATA[bru1]]></name>
				<uri>https://forexsb.com/forum/user/8921/</uri>
			</author>
			<updated>2017-04-05T10:33:18Z</updated>
			<id>https://forexsb.com/forum/post/42686/#p42686</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: Custom order comment]]></title>
			<link rel="alternate" href="https://forexsb.com/forum/post/42678/#p42678" />
			<content type="html"><![CDATA[<p>Add the following line at the beginning of the expert. This will allow you to enter a comment on the expert&#039;s Input tab.</p><div class="codebox"><pre><code>static input string Order_Comment = &quot;&quot;; // Custom order comment</code></pre></div><p><span class="postimg"><img src="http://s10.postimg.org/ktp22ch8p/screenshot_193.png" alt="http://s10.postimg.org/ktp22ch8p/screenshot_193.png" /></span></p><p>Set the EA to attach the comment to a position. You have to modify the <strong>OpenPosition</strong> function. There are two ways:</p><p>Variant 1.&nbsp; replace the default comment (the EA&#039;s magic number)<br /></p><div class="codebox"><pre><code>// Replace

 string comment    = IntegerToString(Magic_Number);

// with

      string comment    = Order_Comment;</code></pre></div><p><span class="postimg"><img src="http://s10.postimg.org/oh9em5etl/screenshot_194.png" alt="http://s10.postimg.org/oh9em5etl/screenshot_194.png" /></span></p><br /><p>Variant 2. Add your custom comment to the EA&#039;s magic number:</p><div class="codebox"><pre><code>string comment    = IntegerToString(Magic_Number) + &#039; &#039; + Order_Comment;</code></pre></div><p><span class="postimg"><img src="http://s10.postimg.org/z5d5kzosp/screenshot_195.png" alt="http://s10.postimg.org/z5d5kzosp/screenshot_195.png" /></span></p>]]></content>
			<author>
				<name><![CDATA[Popov]]></name>
				<uri>https://forexsb.com/forum/user/2/</uri>
			</author>
			<updated>2017-04-05T07:15:12Z</updated>
			<id>https://forexsb.com/forum/post/42678/#p42678</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: Custom order comment]]></title>
			<link rel="alternate" href="https://forexsb.com/forum/post/42672/#p42672" />
			<content type="html"><![CDATA[<p>I think you can, try it out. If something comes up, report back and lets work through it.</p>]]></content>
			<author>
				<name><![CDATA[footon]]></name>
				<uri>https://forexsb.com/forum/user/1242/</uri>
			</author>
			<updated>2017-04-04T22:03:33Z</updated>
			<id>https://forexsb.com/forum/post/42672/#p42672</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Custom order comment]]></title>
			<link rel="alternate" href="https://forexsb.com/forum/post/42671/#p42671" />
			<content type="html"><![CDATA[<p>Hello,<br />I am wondering if maybe I can add in an EA-Studio expert a &quot;Custom order comment&quot; (as suggested in the wish list) myself, using following line (from FSB experts):<br /></p><div class="codebox"><pre><code>static input string Order_Comment = &quot;&quot;; // Custom order comment</code></pre></div><p>Or do I need more,<br />Thank you for any advise.</p>]]></content>
			<author>
				<name><![CDATA[bru1]]></name>
				<uri>https://forexsb.com/forum/user/8921/</uri>
			</author>
			<updated>2017-04-04T20:39:37Z</updated>
			<id>https://forexsb.com/forum/post/42671/#p42671</id>
		</entry>
</feed>
