How to detect that someone was at work between 22:00 and 6:00. I've never dealt with calculations of the time so I do not know how to go about it?
(timeof(now)>22/24.0) or (timeof(now)<6/24.0)
(myvar >= (today+EncodeTime(22,00,00,00))) and (Myvar < (today+1+EncodeTime(06,00,00,00)))