MQL5 - Language of trade strategies built-in the MetaTrader 5 client terminal

Automated Trading Language Documentation

Screenshot
EURUSD, M5
Real
Subscribe to signal
Automatic system hedging v 5 217 6
11.06%, 435 217.38 USD
MQL5 Cloud Network: Are You Still Calculating? MQL5 Cloud Network: Are You Still Calculating? Fuzzy Logic Portfolio Selection Criteria FREEFuzzy Logic Portfolio Selection Criteria FREE Try product
Fuzzy Logic Portfolio Selection Criteria FREE
Author: figurelli
IncTrixOnArray Library
IncTrixOnArray
Author: Integer
MQL5 ReferenceTrade FunctionsHistoryOrderGetDouble 

HistoryOrderGetDouble

Returns the requested order property. The order property must be of the double type. There are 2 variants of the function.

1. Immediately returns the property value.

double  HistoryOrderGetDouble(
   ulong                       ticket_number,     // Ticket
   ENUM_ORDER_PROPERTY_DOUBLE  property_id        // Property identifier
   );

2. Returns true or false, depending on the success of the function. If successful, the value of the property is placed into a target variable passed by reference by the last parameter.

bool  HistoryOrderGetDouble(
   ulong                       ticket_number,     // Ticket
   ENUM_ORDER_PROPERTY_DOUBLE  property_id,       // Property identifier
   double&                     double_var         // Here we accept the property value
   );

Parameters

ticket_number

[in]  Order ticket.

property_id

[in]  Identifier of the order property. The value can be one of the values of the ENUM_ORDER_PROPERTY_DOUBLE enumeration.

double_var

[out]  Variable of the double type that accepts the value of the requested property.

Return Value

Value of the double type.

Note

Do not confuse orders of a trading history with current pending orders that appear on the "Trade" tab of the "Toolbox" bar. The list of orders that were canceled or have led to a transaction, can be viewed in the "History" tab of "Toolbox" of the client terminal.

See also

HistorySelect(), HistoryOrdersTotal(), HistoryOrderSelect(), Order Properties


Updated: 2010.11.01