×

Sign up and get MultiCharts free

Use its powerful simulation mode with data included out of the box. Just fill out the form and start honing your trading skills with a few clicks.

Changes - MultiCharts
Open main menu

Changes

Setting dynamic order name

1,545 bytes added, 11:37, 16 September 2013
Created page with "Dynamic order name feature has been introduced in MultiCharts 8.8 beta 1. Now it is possible to generate the order name basing on script calculation. ===The types of avail..."
Dynamic order name feature has been introduced in MultiCharts 8.8 beta 1.

Now it is possible to generate the order name basing on script calculation.

===The types of available order naming algorithms===

* Order with automatically generated names

<syntaxhighlight>
buy next bar market;
</syntaxhighlight>

* Order with pre-set static order name

<syntaxhighlight>
buy("My Buy") next bar market;
</syntaxhighlight>

* Order with sting variable name

<syntaxhighlight>
Var: NLong("Long ");
NLong = NLong + NumToStr(currentbar, 0);
buy(NLong) next bar market;
</syntaxhighlight>

* Order with string sentense name

<syntaxhighlight>
Var: NLong("Long ");
NLong = NLong + NumToStr(currentbar, 0);
buy(NLong + " Limit") next bar с limit;
</syntaxhighlight>

* Order with compound sentence name

<syntaxhighlight>
Var: NLong("Long ");
NLong = NLo`ng + NumToStr(currentbar, 0);
buy (NLong + " at " + NumToStr(c, 2) + " Limit") next bar c limit;
</syntaxhighlight>

* Exit From Entry structure

<syntaxhighlight>
Var: Nl("Long ");
buy (Nl + "Entry") 5 shares next bar c limit;
sell (Nl + "SL Exit" + " Low bar") from Entry(Nl + "Entry") next bar l stop;
</syntaxhighlight>

<div style="background-color: #E3FBE5;">'''Notes''':
# It is not possible to give an order the name that has already been used for another line of script. It will make a study be turned off.
# Make sure that appropriate names are used for "Exit From Entry" logic. If there's no any order with the set name - position won't be closed. </div>

[[Category:Strategy_Orders]]