×

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

Changes

Jump to navigation Jump to search

Begin

380 bytes removed, 12:29, 20 January 2012
no edit summary
Used in combination with <syntaxhighlight>[[End</syntaxhighlight> ]] to group instructions for conditional execution; a <syntaxhighlight>[[Begin</syntaxhighlight> ]] must always be followed by an <syntaxhighlight>[[End.</syntaxhighlight> ]] <syntaxhighlight>[[Begin</syntaxhighlight> ]] and <syntaxhighlight>[[End</syntaxhighlight> ]] can be used with <syntaxhighlight>[[Then, Else, For,</syntaxhighlight> ]] and <syntaxhighlight>[[While</syntaxhighlight> ]] conditional statements.
<syntaxhighlight>[[Begin</syntaxhighlight> ]] should not be followed by a semicolon (;), code lines within an instruction group should end with a semicolon (;), and only the last instance of <syntaxhighlight>[[End</syntaxhighlight> ]] within the same conditional execution statement should be followed by a semicolon (;).
==== Usage ====
<syntaxhighlight>CS Begin</syntaxhighlight>
I1;
I2;
I3;
<syntaxhighlight>End;</syntaxhighlight>
Where: <syntaxhighlight>[[CS</syntaxhighlight> ]] - conditional statement
I - conditional instructions
If UpTrend is true then buy, otherwise sell short:
<syntaxhighlight>If</syntaxhighlight> UpTrend <syntaxhighlight>Then Begin
Buy Next Bar Market;
End
Anonymous user

Navigation menu