获取最近一张持仓订单的订单编号
函数获取最近持仓订单的订单编号。int LastLongBuy() {
for (int l_pos_0 = OrdersTotal() - 1; l_pos_0 >= 0; l_pos_0--) {
if (OrderSelect(l_pos_0, SELECT_BY_POS, MODE_TRADES) && OrderTicket() >
g_ticket_164) {
g_ticket_164 = OrderTicket();
return (g_ticket_164);
}
}
return (-1);}
页:
[1]