Checkin if hour is within timespan

ok, Ive been fighting with this for a while and I am stuck…

What is the straightforward way to check if NowTime.hour is within 19 and 06 hours ?

I think this works… found it on SO…

[code]if from < till then

if Nowtime.Hour >= val(from) and Nowtime.Hour <= val(till) then
/// run



if Nowtime.Hour >= val(from) or Nowtime.Hour <= val(till) then
/// run



Thanks Julian… I had set 19 and 6 just as dummy dates… I understand the logic, though…

Convert initial,final and test time/date (yes, with date) to TotalSeconds

Test if test time is between initial and final (just an idea)