//北京时区,判 断日盘还是夜盘,15分钟周期图表
if time >=opentime(2) and time <=closetime(4) then DorN:=1;
else if time >=opentime(1) and time <=closetime(1) then DorN:=2;
else DorN=0; //DorN: 1日盘,2夜盘,0非交易时间。
为什么在21:30:00这样的时间里,DorN=1?
另外,在图表中,如何判断当前K线时间距离收盘还有不到15分钟?
if time >=opentime(2) and time <=closetime(3) then DorN:=1;
else if time >=opentime(1) and time <=closetime(1) then DorN:=2;
else DorN:=0; //DorN: 1日盘,2夜盘,0非交易时间。
[此贴子已经被作者于2016/2/15 9:31:58编辑过]
北京时区。
[此贴子已经被作者于2016/2/15 9:52:27编辑过]
if time >=090000 and time <=150000 then DorN:=1;
else if (time >=210000 and time <=235959) or (time>=000000 and time<=010000) then DorN:=2;
else DorN:=0; //DorN: 1日盘,2夜盘,0非交易时间。