SetOrderQuantity

<< Click to Display Table of Contents >>

Navigation:  NinjaScript > Language Reference > Strategy >

SetOrderQuantity

Previous page Return to chapter overview Next page

Definition

Determines how order sizes are calculated for a given strategy.

 

Property Value

An enum determining how order quantities are set.  Default value is set to SetOrderQuantity.Strategy.

 

Possible values are:

SetOrderQuantity.DefaultQuantity

User defined order size based on the DefaultQuantity property

SetOrderQuantity.Strategy

Takes the order size specified programmatically within the strategy

 

Syntax

SetOrderQuantity

 

 

Examples

ns


protected override void OnStateChange()
{
    if (State == State.Configure)
    {
        SetOrderQuantity = SetOrderQuantity.DefaultQuantity; // calculate orders based off default size
    }
}