Difference between revisions of "SetStopContract"
Jump to navigation
Jump to search
Line 1: | Line 1: | ||
− | Forces the built-in strategy exit functions to be applied on per contract or share basis. | + | Forces the built-in strategy exit functions to be applied on per contract or share basis. |
− | |||
− | + | The built-in strategy exit functions are: [[SetStopLoss]], [[SetProfitTarget]], [[SetBreakEven]], [[SetDollarTrailing]], and [[SetPercentTrailing]]. | |
+ | |||
+ | == Usage == | ||
<syntaxhighlight>SetStopContract</syntaxhighlight> | <syntaxhighlight>SetStopContract</syntaxhighlight> | ||
− | + | == Notes == | |
− | If [[ | + | * If [[SetStopPosition]], '''SetStopContract''', and [[SetStopShare]] were not used, the exit functions will be applied on the entire position basis as a default. |
− | + | * If [[SetStopPosition]], '''SetStopContract''', and [[SetStopShare]] were used in multiple instances or in different signals applied to the same chart, the last instance will be controlling. | |
− | [[ | ||
− | + | == Example == | |
Force the SetStopLoss strategy exit function to be applied on per contract basis: | Force the SetStopLoss strategy exit function to be applied on per contract basis: | ||
− | |||
<syntaxhighlight>SetStopContract; | <syntaxhighlight>SetStopContract; | ||
SetStopLoss(10);</syntaxhighlight> | SetStopLoss(10);</syntaxhighlight> | ||
− | |||
An exit order for the entry will be generated if the loss per contract reaches $10. | An exit order for the entry will be generated if the loss per contract reaches $10. | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
[[Category:Strategy Orders]] | [[Category:Strategy Orders]] |
Latest revision as of 16:52, 19 February 2012
Forces the built-in strategy exit functions to be applied on per contract or share basis.
The built-in strategy exit functions are: SetStopLoss, SetProfitTarget, SetBreakEven, SetDollarTrailing, and SetPercentTrailing.
Usage
SetStopContract
Notes
- If SetStopPosition, SetStopContract, and SetStopShare were not used, the exit functions will be applied on the entire position basis as a default.
- If SetStopPosition, SetStopContract, and SetStopShare were used in multiple instances or in different signals applied to the same chart, the last instance will be controlling.
Example
Force the SetStopLoss strategy exit function to be applied on per contract basis:
SetStopContract;
SetStopLoss(10);
An exit order for the entry will be generated if the loss per contract reaches $10.