Order functions are mostly used for accessing the strategy orders in the orders table. Each strategy in the Desktop has its own separate orders table which it uses to hold all of its orders. The indexes of those orders in the table are used to identify the orders when using the Order functions (see the OrderByStatus functions to access those order indexes).


Sections


Functions

Function Details


Functions


Name

Description

C_ActionType OrderActionType(int)

Gets the action type of a specified order.

C_ActionType OrderActionType(int, int)

Gets the action type of a specified order.

int[] OrderAttachedOrders(int)

Gets the attached order indexes of a specified order.

int[] OrderAttachedOrders(int, int)

Gets the attached order indexes of a specified order.

int[] OrderByStatus(C_Status)

Gets the indexes of the orders in a specified status that belong to the underlying symbol.

int[] OrderByStatus(int, C_Status, int?)

Gets the indexes of the orders in a specified status that belong to a specified strategy.

int[] OrderByStatusAll(C_Status)

Gets the indexes of the orders in a specified status that belong to any of the strategy symbols.

string OrderComment(int)

Gets the comment describing a specified order.

string OrderComment(int, int)

Gets the comment describing a specified order.

double OrderCommission(int)

Gets the commission paid for a specified order.

double OrderCommission(int, int)

Gets the commission paid for a specified order.

int OrderCount()

Gets the number of orders of the underlying symbol.

int OrderCount(int)

Gets the number of orders of a specified strategy.

int OrderCountAll()

Gets the total number of orders for all of the symbols.

int OrderCountByStatus(C_Status)

Gets the number of orders of the underlying symbol in a specified status.

int OrderCountByStatus(int, C_Status, int?)

Gets the number of orders of a specified strategy in a specified status.

int OrderCountByStatusAll(C_Status)

Gets the total number of orders, for all of the symbols, in a specified status.

long OrderCreateDateTime(int)

Gets the date/time in which a specified order was created.

long OrderCreateDateTime(int, int)

Gets the date/time in which a specified order was created.

string OrderCurrencyCode(int)

Gets the currency code of a specified order. (USD, EUR, GPB etc.)

string OrderCurrencyCode(int, int)

Gets the currency code of a specified order. (USD, EUR, GPB etc.)

C_Direction OrderDirection(int)

Gets the order direction of a specified order.

C_Direction OrderDirection(int, int)

Gets the order direction of a specified order.

bool OrderExists(C_Status, C_ActionType?)

Determines whether a specified order exists.

bool OrderExists(int, C_Status, C_ActionType?, int?)

Determines whether a specified order exists.

bool OrderExistsAll(C_Status, C_ActionType?)

Determines whether a specified order exists for any of the symbols.

double OrderExpectedPrice(int)

Gets the expected execution price of a specified order.

double OrderExpectedPrice(int, int)

Gets the expected execution price of a specified order.

int OrderFillCount(int)

Gets the number of order fills for a specified order.

int OrderFillCount(int, int)

Gets the number of order fills for a specified order.

double OrderFillPrice(int, int)

Gets the price of a specified order fill.

double OrderFillPrice(int, int, int)

Gets the price of a specified order fill.

double OrderFillQuantity(int, int)

Gets the quantity of a specified order fill.

double OrderFillQuantity(int, int, int)

Gets the quantity of a specified order fill.

C_Instrument OrderInstrumentType(int)

Gets the instrument type of a specified order.

C_Instrument OrderInstrumentType(int, int)

Gets the instrument type of a specified order.

bool OrderIsAcknowledged(int)

Determines whether a specified order has been acknowledged by the broker.

bool OrderIsAcknowledged(int, int)

Determines whether a specified order has been acknowledged by the broker.

bool OrderIsAllOrNone(int)

Determines whether a specified order is an all or none order.

bool OrderIsAllOrNone(int, int)

Determines whether a specified order is an all or none order.

bool OrderIsCancelRequested(int)

Determines whether a specified order has been requested to be cancelled.

bool OrderIsCancelRequested(int, int)

Determines whether a specified order has been requested to be cancelled.

bool OrderIsPercentOffset(int)

Determines whether the offset price of a specified order is a percent offset or a fixed offset.

bool OrderIsPercentOffset(int, int)

Determines whether the offset price of a specified order is a percent offset or a fixed offset.

bool OrderIsStopHit(int)

Determines whether the stop price of a specified stop limit order has been hit.

bool OrderIsStopHit(int, int)

Determines whether the stop price of a specified stop limit order has been hit.

double OrderLimitPrice(int)

Gets the limit price of a specified order.

double OrderLimitPrice(int, int)

Gets the limit price of a specified order.

double OrderPrice(int)

Gets the average fill price of a specified order.

double OrderPrice(int, int)

Gets the average fill price of a specified order.

double OrderPriceOffset(int)

Gets the percent or fixed price offset of a specified order.

double OrderPriceOffset(int, int)

Gets the percent or fixed price offset of a specified order.

C_OrderType OrderPriceType(int)

Gets the order type of a specified order.

C_OrderType OrderPriceType(int, int)

Gets the order type of a specified order.

double OrderQuantity(int)

Gets the quantity of a specified order.

double OrderQuantity(int, int)

Gets the quantity of a specified order.

double OrderQuantityFilled(int)

Gets the filled quantity of a specified order.

double OrderQuantityFilled(int, int)

Gets the filled quantity of a specified order.

double OrderQuantityRemaining(int)

Gets the remaining quantity of a specified order.

double OrderQuantityRemaining(int, int)

Gets the remaining quantity of a specified order.

long OrderSimAccountId(int)

Gets the sim-account Id of a specified order.

double OrderSlippageCost(int)

Gets the slippage cost of a specified order.

double OrderSlippageCost(int, int)

Gets the slippage cost of a specified order.

C_Status OrderStatus(int)

Gets the status of a specified order (Pending, Cancelled, Executed).

C_Status OrderStatus(int, int)

Gets the status of a specified order (Pending, Cancelled, Executed).

long OrderStatusDateTime(int)

Gets the date/time in which the status of a specified order was last updated.

long OrderStatusDateTime(int, int)

Gets the date/time in which the status of a specified order was last updated.

double OrderStopPrice(int)

Gets the stop price of a specified order.

double OrderStopPrice(int, int)

Gets the stop price of a specified order.

int OrderSymbolIndex(int)

Gets the symbol index in the symbols table of a specified order.

int OrderSymbolIndex(int, int)

Gets the symbol index in the symbols table of a specified order.

C_TIF OrderTIF(int)

Gets the time in force (TIF) of a specified order.

C_TIF OrderTIF(int, int)

Gets the time in force (TIF) of a specified order.


Function Details


C_ActionType OrderActionType(int orderIndex)

Gets the action type of a specified order.


Returns


The action type of the specified order. (View Options)


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


C_ActionType OrderActionType(int strategyNumber, int orderIndex)

Gets the action type of a specified order.


Returns


The action type of the specified order. (View Options)


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


int[] OrderAttachedOrders(int orderIndex)

Gets the attached order indexes of a specified order.


Returns


The attached order indexes of the specified order.


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


int[] OrderAttachedOrders(int strategyNumber, int orderIndex)

Gets the attached order indexes of a specified order.


Returns


The attached order indexes of the specified order.


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


int[] OrderByStatus(C_Status orderStatus)

Gets the indexes of the orders in a specified status that belong to the underlying symbol.


Returns


The indexes of the orders in the specified status that belong to the underlying symbol.


Parameters


Type

Identifier

Description

C_Status

orderStatus

The order status (View Options)


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


int[] OrderByStatus(int strategyNumber, C_Status orderStatus, int? symbolIndex)

Gets the indexes of the orders in a specified status that belong to a specified strategy.


Returns


The indexes of the orders in the specified status that belong to a specified strategy.


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

C_Status

orderStatus

The order status (View Options)

int?

symbolIndex

The symbol index in the symbols table (Optional - null for all symbols)


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


int[] OrderByStatusAll(C_Status orderStatus)

Gets the indexes of the orders in a specified status that belong to any of the strategy symbols.


Returns


The indexes of the orders in a specified status that belong to any of the strategy symbols.


Parameters


Type

Identifier

Description

C_Status

orderStatus

The order status (View Options)


Scripts


MultiSymbolTradingStrategy


string OrderComment(int orderIndex)

Gets the comment describing a specified order.


Returns


The comment describing the specified order.


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


string OrderComment(int strategyNumber, int orderIndex)

Gets the comment describing a specified order.


Returns


The comment describing the specified order.


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


double OrderCommission(int orderIndex)

Gets the commission paid for a specified order.


Returns


The commission paid for the specified order.


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


double OrderCommission(int strategyNumber, int orderIndex)

Gets the commission paid for a specified order.


Returns


The commission paid for the specified order.


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


int OrderCount()

Gets the number of orders of the underlying symbol.


Returns


The number of orders of the underlying symbol.


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


int OrderCount(int strategyNumber)

Gets the number of orders of a specified strategy.


Returns


The number of orders of the specified strategy.


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


int OrderCountAll()

Gets the total number of orders for all of the symbols.


Returns


The total number of orders for all of the symbols.


Scripts


MultiSymbolTradingStrategy


int OrderCountByStatus(C_Status orderStatus)

Gets the number of orders of the underlying symbol in a specified status.


Returns


The number of orders of the underlying symbol in a specified status.


Parameters


Type

Identifier

Description

C_Status

orderStatus

The order status (View Options)


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


int OrderCountByStatus(int strategyNumber, C_Status orderStatus, int? symbolIndex)

Gets the number of orders of a specified strategy in a specified status.


Returns


The number of orders of a specified strategy in a specified status.


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

C_Status

orderStatus

The order status (View Options)

int?

symbolIndex

The symbol index in the symbols table (Optional - null for all symbols)


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


int OrderCountByStatusAll(C_Status orderStatus)

Gets the total number of orders, for all of the symbols, in a specified status.


Returns


The total number of orders, for all of the symbols, in a specified status.


Parameters


Type

Identifier

Description

C_Status

orderStatus

The order status (View Options)


Scripts


MultiSymbolTradingStrategy


long OrderCreateDateTime(int orderIndex)

Gets the date/time in which a specified order was created.


Returns


The date/time in which the specified order was created.


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


long OrderCreateDateTime(int strategyNumber, int orderIndex)

Gets the date/time in which a specified order was created.


Returns


The date/time in which the specified order was created.


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


string OrderCurrencyCode(int orderIndex)

Gets the currency code of a specified order. (USD, EUR, GPB etc.)


Returns


The currency code of the specified order. (USD, EUR, GPB etc.)


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


string OrderCurrencyCode(int strategyNumber, int orderIndex)

Gets the currency code of a specified order. (USD, EUR, GPB etc.)


Returns


The currency code of the specified order. (USD, EUR, GPB etc.)


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


C_Direction OrderDirection(int orderIndex)

Gets the order direction of a specified order.


Returns


The order direction of the specified order. (View Options)


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


C_Direction OrderDirection(int strategyNumber, int orderIndex)

Gets the order direction of a specified order.


Returns


The order direction of the specified order. (View Options)


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


bool OrderExists(C_Status orderStatus, C_ActionType? actionType)

Determines whether a specified order exists.


Returns


True if the specified order exists, false otherwise.


Parameters


Type

Identifier

Description

C_Status

orderStatus

The order status (View Options)

C_ActionType?

actionType

The action type (View Options)


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


bool OrderExists(int strategyNumber, C_Status orderStatus, C_ActionType? actionType, int? symbolIndex)

Determines whether a specified order exists.


Returns


True if the specified order exists, false otherwise.


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

C_Status

orderStatus

The order status (View Options)

C_ActionType?

actionType

The action type (View Options) (Optional - null for all actions)

int?

symbolIndex

The symbol index in the symbols table (Optional - null for all symbols)


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


bool OrderExistsAll(C_Status orderStatus, C_ActionType? actionType)

Determines whether a specified order exists for any of the symbols.


Returns


True if the specified order exists for any of the symbols, false otherwise.


Parameters


Type

Identifier

Description

C_Status

orderStatus

The order status (View Options)

C_ActionType?

actionType

The action type (View Options)


Scripts


MultiSymbolTradingStrategy


double OrderExpectedPrice(int orderIndex)

Gets the expected execution price of a specified order.


Returns


The expected execution price of the specified order.


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


double OrderExpectedPrice(int strategyNumber, int orderIndex)

Gets the expected execution price of a specified order.


Returns


The expected execution price of the specified order.


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


int OrderFillCount(int orderIndex)

Gets the number of order fills for a specified order.


Returns


The number of order fills for the specified order.


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


int OrderFillCount(int strategyNumber, int orderIndex)

Gets the number of order fills for a specified order.


Returns


The number of order fills for the specified order.


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


double OrderFillPrice(int orderIndex, int orderFillIndex)

Gets the price of a specified order fill.


Returns


The price of the specified order fill.


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table

int

orderFillIndex

The order fill index (0 to OrderFillCount - 1)


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


double OrderFillPrice(int strategyNumber, int orderIndex, int orderFillIndex)

Gets the price of a specified order fill.


Returns


The price of the specified order fill.


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table

int

orderFillIndex

The order fill index (0 to OrderFillCount - 1)


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


double OrderFillQuantity(int orderIndex, int orderFillIndex)

Gets the quantity of a specified order fill.


Returns


The quantity of the specified order fill.


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table

int

orderFillIndex

The order fill index (0 to OrderFillCount - 1)


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


double OrderFillQuantity(int strategyNumber, int orderIndex, int orderFillIndex)

Gets the quantity of a specified order fill.


Returns


The quantity of the specified order fill.


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table

int

orderFillIndex

The order fill index (0 to OrderFillCount - 1)


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


C_Instrument OrderInstrumentType(int orderIndex)

Gets the instrument type of a specified order.


Returns


The instrument type of the specified order. (View Options)


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


C_Instrument OrderInstrumentType(int strategyNumber, int orderIndex)

Gets the instrument type of a specified order.


Returns


The instrument type of the specified order. (View Options)


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


bool OrderIsAcknowledged(int orderIndex)

Determines whether a specified order has been acknowledged by the broker.


Returns


True if the specified order has been acknowledged by the broker, false otherwise.


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


bool OrderIsAcknowledged(int strategyNumber, int orderIndex)

Determines whether a specified order has been acknowledged by the broker.


Returns


True if the specified order has been acknowledged by the broker, false otherwise.


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


bool OrderIsAllOrNone(int orderIndex)

Determines whether a specified order is an all or none order.


Returns


True if the specified order is an all or none order, false otherwise.


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


bool OrderIsAllOrNone(int strategyNumber, int orderIndex)

Determines whether a specified order is an all or none order.


Returns


True if the specified order is an all or none order, false otherwise.


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


bool OrderIsCancelRequested(int orderIndex)

Determines whether a specified order has been requested to be cancelled.


Returns


True if the specified order has been requested to be cancelled, false otherwise.


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


bool OrderIsCancelRequested(int strategyNumber, int orderIndex)

Determines whether a specified order has been requested to be cancelled.


Returns


True if the specified order has been requested to be cancelled, false otherwise.


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


bool OrderIsPercentOffset(int orderIndex)

Determines whether the offset price of a specified order is a percent offset or a fixed offset.


Returns


True if the offset price of a specified order is a percent offset, false if it's a fixed offset.


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


bool OrderIsPercentOffset(int strategyNumber, int orderIndex)

Determines whether the offset price of a specified order is a percent offset or a fixed offset.


Returns


True if the offset price of a specified order is a percent offset, false if it's a fixed offset.


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


bool OrderIsStopHit(int orderIndex)

Determines whether the stop price of a specified stop limit order has been hit.


Returns


True if the stop price of the specified stop limit order has been hit.


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


bool OrderIsStopHit(int strategyNumber, int orderIndex)

Determines whether the stop price of a specified stop limit order has been hit.


Returns


True if the stop price of the specified stop limit order has been hit.


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


double OrderLimitPrice(int orderIndex)

Gets the limit price of a specified order.


Returns


The limit price of the specified order.


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


double OrderLimitPrice(int strategyNumber, int orderIndex)

Gets the limit price of a specified order.


Returns


The limit price of the specified order.


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


double OrderPrice(int orderIndex)

Gets the average fill price of a specified order.


Returns


The averge fill price of the specified order. 


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


double OrderPrice(int strategyNumber, int orderIndex)

Gets the average fill price of a specified order.


Returns


The average fill price of the specified order. 


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


double OrderPriceOffset(int orderIndex)

Gets the percent or fixed price offset of a specified order.


Returns


The percent or fixed price offset of the specified order.


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


double OrderPriceOffset(int strategyNumber, int orderIndex)

Gets the percent or fixed price offset of a specified order.


Returns


The percent or fixed price offset of the specified order.


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


double OrderQuantity(int orderIndex)

Gets the quantity of a specified order.


Returns


The quantity of the specified order. 


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


double OrderQuantity(int strategyNumber, int orderIndex)

Gets the quantity of a specified order.


Returns


The quantity of the specified order.


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


C_OrderType OrderPriceType(int orderIndex)

Gets the order type of a specified order.


Returns


The order type of the specified order. 


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


C_OrderType OrderPriceType(int strategyNumber, int orderIndex)

Gets the order type of a specified order.


Returns


The order type of the specified order.


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


double OrderQuantityFilled(int orderIndex)

Gets the filled quantity of a specified order.


Returns


The filled quantity of the specified order.


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


double OrderQuantityFilled(int strategyNumber, int orderIndex)

Gets the filled quantity of a specified order.


Returns


The filled quantity of the specified order.


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


double OrderQuantityRemaining(int orderIndex)

Gets the remaining quantity of a specified order.


Returns


The remaining quantity of the specified order.


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


double OrderQuantityRemaining(int strategyNumber, int orderIndex)

Gets the remaining quantity of a specified order.


Returns


The remaining quantity of the specified order.


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


long OrderSimAccountId(int orderIndex)

Gets the sim-account Id of a specified order.


Returns


The sim-account Id for the specified order.


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table


Scripts


TradeManagementStrategy


double OrderSlippageCost(int orderIndex)

Gets the slippage cost of a specified order.


Returns


The slippage cost for the specified order.


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


double OrderSlippageCost(int strategyNumber, int orderIndex)

Gets the slippage cost of a specified order.


Returns


The slippage cost for the specified order.


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


C_Status OrderStatus(int orderIndex)

Gets the status of a specified order (Pending, Cancelled, Executed).


Returns


The status of the specified order. (View Options)


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


C_Status OrderStatus(int strategyNumber, int orderIndex)

Gets the status of a specified order (Pending, Cancelled, Executed).


Returns


The status of the specified order. (View Options)


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


long OrderStatusDateTime(int orderIndex)

Gets the date/time in which the status of a specified order was last updated.


Returns


The date/time in which the status of the specified order was last updated.


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


long OrderStatusDateTime(int strategyNumber, int orderIndex)

Gets the date/time in which the status of a specified order was last updated.


Returns


The date/time in which the status of the specified order was last updated.


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


double OrderStopPrice(int orderIndex)

Gets the stop price of a specified order.


Returns


The stop price of the specified order.


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


double OrderStopPrice(int strategyNumber, int orderIndex)

Gets the stop price of a specified order.


Returns


The stop price of the specified order.


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


int OrderSymbolIndex(int orderIndex)

Gets the symbol index in the symbols table of a specified order.


Returns


The symbol index in the symbols table of the specified order.


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


int OrderSymbolIndex(int strategyNumber, int orderIndex)

Gets the symbol index in the symbols table of a specified order.


Returns


The symbol index in the symbols table of the specified order.


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem


C_TIF OrderTIF(int orderIndex)

Gets the time in force (TIF) of a specified order.


Returns


The time in force (TIF) of the specified order. (View Options)


Parameters


Type

Identifier

Description

int

orderIndex

The order index in the orders table


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, PositionSizing, TradingStrategy


C_TIF OrderTIF(int strategyNumber, int orderIndex)

Gets the time in force (TIF) of a specified order.


Returns


The time in force (TIF) of the specified order. (View Options)


Parameters


Type

Identifier

Description

int

strategyNumber

The strategy number

int

orderIndex

The order index in the orders table


Scripts


AddOn, Commission, DynamicAllocation, PerformanceMetric, RiskManagement, Slippage, TaxSystem