Previous Order Functions

Previous Order Functions

You can get all of properties of current open orders. The parameter “n is number of the order. Last order is n=0. One before last order is n=1 and previous one is n=2 and so on.

 PrevOrderProfit[n]Returns profit of the Nth previous order
 PrevOrderStoploss[n]Returns stop loss value of the Nth previous order
 PrevOrderTakeProfit[n]Returns take profit value of the Nth previous order
 PrevOrderOpenPrice[n]Returns open price of the Nth previous order
 PrevOrderCandleReturns candle shift of the Nth previous order
 PrevOrderOpenDuration[n]Returns open duration of the Nth previous order in seconds
 PrevOrderOpenYear[n]Returns the year of Nth previous order open time
 PrevOrderOpenMonth[n]Returns the month of Nth previous order open time
 PrevOrderOpenDay[n]Returns the day of Nth previous order open time
 PrevOrderOpenDayOFWeek[n]Returns the week day of Nth previous order open time
 PrevOrderOpenDayOFYear[n]Returns the year day of Nth previous order open time
 PrevOrderOpenHour[n]Returns the hour of Nth previous order open time
 PrevOrderOpenMinute[n]Returns the minute of Nth previous order open time
 PrevOrderOpenSecond[n]Returns the second of Nth previous order open time
 PrevOrderOpenWeek[n]Returns the week number of Nth previous order open time
 PrevOrderSwap[n]Returns swap value of the Nth previous order
 PrevOrderLots[n]Returns amount of lots of the Nth previous order
 PrevOrderTicket[n]Returns ticket number of the Nth previous order
 PrevOrderCommission[n]Returns calculated commission of the Nth previous order
 PrevOrderProfitPoints[n]Returns profit of the Nth previous order in points
 PrevOrderLossPoints[n]Returns loss of the Nth previous order in points
 PrevOrderIsBuy[n]Returns True if Nth previous order type is buy
 PrevOrderIsSell[n]Returns True if Nth previous order type is sell