后台,1分钟周期 逐K 下运行:
怎样记录,上跳到这个周期的H次数,都没突破
globalvariable:tt=0,hh=0;
globalvariable:cs:=0;
if tt=0 and hh=0 then begin
tt:=time;
hh:=h;
end//赋初值
if tt<>time then begin
tt:=time;
hh:=h;
cs:=0;
end//新k线出现时重新赋值
if dynainfo(207)=h then cs:=cs+1;
cs为所求值
globalvariable:tt=0,hh=0;
globalvariable:cs:=0;
如下写可以吗?比较简单
globalvariable:tt=0,hh=0,CS=0;