用开仓指令:
开空:
sellKc=m_trade.PositionOpen(dqhy,ORDER_TYPE_SELL,开仓量,SymbolInfoDouble(dqhy,SYMBOL_SESSION_PRICE_LIMIT_MIN),0,0,区分订单);
开多:
buyKc=m_trade.PositionOpen(dqhy,ORDER_TYPE_BUY,开仓量,SymbolInfoDouble(dqhy,SYMBOL_SESSION_PRICE_LIMIT_MAX),0,0,区分订单);
以跌停价开空,以涨停价开多,对有些品种能成功开仓,没有任何问题。
但对另一些品种,会出现报价为 零 的情况,
例如:苹果、棉花、甲醇,都可以开仓成功,但红枣、玻璃、菜油、短纤等品种,用同样的命令开仓时会直接提示:
CTrade::OrderSend: instant return remainder buy 1.00 CJ201 at 0 [placed]
CTrade::OrderSend: instant return remainder buy 1.00 FG201 at 0 [placed]
CTrade::OrderSend: instant return remainder buy 1.00 OI201 at 0 [placed]
CTrade::OrderSend: instant return remainder buy 1.00 PF201 at 0 [placed]
从而导致开仓失败。这是什么原因?应如何解决?
|