Forums › ProRealTime English forum › ProBuilder support › Determine the charts time frame in a program › Reply To: Determine the charts time frame in a program
04/19/2020 at 10:13 AM
#126843
This does the part of counting bars that actually exist and works in v10.3. Obviously it takes at minimum three days to establish a result. I’ll have to work on counting bars that don’t actually exist!
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 |
if barsinday = 0 then count = count+1 if opendayofweek <> opendayofweek[1] then day1 = day2 day2 = day3 day3 = count count = 0 if day1 <> 0 and (day1+day2+day3)/3 = day3 then barsinday = day3 endif endif endif return barsinday |