与大家共享分析的快乐

 

在某段时间平掉多单和空单的模块:

if((TimeHour(CurTime()) < StartHour) || (TimeHour(CurTime()) >= EndHour) ||
(DayOfWeek() == KillDay && TimeHour(CurTime()) == KillHour))
{
total = OrdersTotal();
//----
for(cnt = 0; cnt < total; cnt++)
{// 3
OrderSelect(cnt, SELECT_BY_POS, MODE_TRADES);
//----
if(OrderSymbol() == Symbol())
{ //4
if(OrderType() == OP_BUY)
{ //5
OrderClose(OrderTicket(),Lots,Bid,Slippage,Green);
return(0);
} //5
//----
if(OrderType() == OP_SELL)
{ //5
OrderClose(OrderTicket(), Lots, Ask, Slippage, Green);
return(0);
} //5
} //4
} //3
return(0);
}

私下联系QQ 1031130533