以文本方式查看主题 - 金字塔客服中心 - 专业程序化交易软件提供商 (http://weistock.com/bbs/index.asp) -- 公式模型编写问题提交 (http://weistock.com/bbs/list.asp?boardid=4) ---- 后台编写问题请教 (http://weistock.com/bbs/dispbbs.asp?boardid=4&id=64549) |
|
-- 作者:系统使用者 -- 发布时间:2014/4/30 12:25:47 -- 后台编写问题请教
|
|
-- 作者:系统使用者 -- 发布时间:2014/4/30 12:28:20 -- 若编写错误,应该如何编写请赐教,谢谢 |
|
-- 作者:jinzhe -- 发布时间:2014/4/30 13:28:33 -- 1.单子没成交那你应该是撤单而不是平仓啊,你没成交哪里能够平单子 if tisremain(0)>0 then tcancel(1,0); end
2. orderqueue可以用在后台
3. 时间判断时,用time可以用=判断,可以time=090100; 但是用currenttime,你需要用一个时间段来控制,比如这样 currenttime>145800 and currenttime<=145900
|
|
-- 作者:系统使用者 -- 发布时间:2014/4/30 21:39:57 -- if tisremain(0)>0 then begin tcancel(0,0); tsell(1,10,mkt); tsellshort(1,10,mkt); end if tisremain(0)>0 then begin tcancel(0,0); tsell(1,10,mkt); tsellshort(1,10,mkt); end if THOLDING2=0 and currenttime>144000 then begin tbuy(1,100,lmt,O,0); tbuyshort(1,100,lmt,O,0); End tsell(cond1,10,mkt); tsellshort(cond2,10,mkt); if CURRENTTIME=145800 then 这样可以了吗? 老大 |
|
-- 作者:系统使用者 -- 发布时间:2014/5/3 22:46:17 -- 这样可以了吗? |
|
-- 作者:jinzhe -- 发布时间:2014/5/4 10:11:30 -- if tisremain(0)>0 then begin tcancel(0,0);
end
tsell(cond1,10,mkt);
tsellshort(cond2,10,mkt); if CURRENTTIME>=145800 and currenttime<=145900 then end |