Difference between revisions of "EntryName"
Jump to navigation
Jump to search
Line 2: | Line 2: | ||
== Usage == | == Usage == | ||
− | <syntaxhighlight>EntryName( | + | <syntaxhighlight>EntryName(PosBack)</syntaxhighlight> |
Where: | Where: | ||
− | :''' | + | : '''PosBack''' - a numerical expression, specifying the number of trade (zero-based). |
+ | : 0 - open position; | ||
+ | : 1 - one position back (the last position closed); | ||
+ | : 2 - two positions back, etc. | ||
== Notes == | == Notes == | ||
− | + | If <code>PosBack</code> is not specified, a value for the open position will be returned. | |
− | == Example == | + | == Example == |
− | <syntaxhighlight> | + | <syntaxhighlight>EntryName(1);</syntaxhighlight> |
− | EntryName(1);</syntaxhighlight> | + | will return a value of "buy LE" for the last closed position, if this position was opened by the order with "buy LE" name. |
− | |||
− | |||
[[Category:Strategy Position]] | [[Category:Strategy Position]] |
Revision as of 13:34, 24 February 2012
Returns the name of the order which opened the position.
Usage
EntryName(PosBack)
Where:
- PosBack - a numerical expression, specifying the number of trade (zero-based).
- 0 - open position;
- 1 - one position back (the last position closed);
- 2 - two positions back, etc.
Notes
If PosBack
is not specified, a value for the open position will be returned.
Example
EntryName(1);
will return a value of "buy LE" for the last closed position, if this position was opened by the order with "buy LE" name.