How to convert string to time and compare with current time?

grafik

 Now.TimeOfDay >= Cdate("09:00").TimeOfDay And Now.TimeOfDay <= Cdate("15:30").TimeOfDay

As well agreed to use Timespan as we can reduce the code chars
grafik

Now.TimeOfDay >= Timespan.Parse("09:00") And Now.TimeOfDay <= Timespan.Parse("15:30")
2 Likes