等级: 免费版
- 注册:
- 2022-9-26
- 曾用名:
|

楼主 |
发表于 2022-9-28 15:17
|
显示全部楼层
这样写行吗?
if TSUBMIT(0)>10 and min(thisremain,nextremain)>0 then begin
if nextremain=thisremain then BEGIN
TCANCELex(1,1,'',nextif);
TCANCELex(1,2,'',thisif);
END
if nextremain>thisremain then BEGIN
TCANCELex(1,1,'',nextif);
TCANCELex(1,2,'',thisif);
tbuy(1,nextremain-thisremain,mkt,0,0,nextif);
END
if nextremain<thisremain then BEGIN
TCANCELex(1,1,'',nextif);
TCANCELex(1,2,'',thisif);
tsell(1,thisremain-nextremain,mkt,0,0,thisif);
END
end
补充内容 (2022-9-28 15:19):
//未成交双撤且补单
nextremain:=TREMAINQTY(1,'' ,nextif);
thisremain:=TREMAINQTY(2,'' ,thisif);
if TSUBMIT(0)>10 and min(thisremain,nextremain)>0 then begin
if nextremain=thisremain then BEGIN
TCANCELex(1,1,'',nextif);
TCANCELex(1,2,'',thisif);
END
if nextremain>thisremain then BEGIN
TCANCELex(1,1,'',nextif);
TCANCELex(1,2,'',thisif);
tbuy(1,nextremain-thisremain,mkt,0,0,nextif);
END
if nextremain<thisremain then BEGIN
TCANCELex(1,1,'',nextif);
TCANCELex(1,2,'',thisif);
tsell(1,thisremain-nextremain,mkt,0,0,thisif);
END
end |
|