Formula to differentiate beween week and weekend

I need to create a formula that can distinguish between days from Monday 09:00 to Friday 14:59:59 - display "Week rate : $12,00" and Friday 15:00 to Monday 08:59:59 - display "Weekend rate : $10,00"
John-S PretoriusTechnical Service Manager, Mid-AtlanticAsked:
Who is Participating?
 
mlmccCommented:
Try this

If DayofWeek({YourDateField}) IN [3,4,5] then
    "Week rate: $12.00"
Else if DayofWeek({YourDateField}) IN [1,7] then
    "Weekend Rate: $10.00"
Else if DayofWeek({YourDateField}) = 6 then
(
      If Time({YourDateField}) < Time(15,0,0) then
          "Week rate: $12.00"
      Else
         "Weekend Rate: $10.00"
)
Else
(
      If Time({YourDateField}) >= Time(9,0,0) then
          "Week rate: $12.00"
      Else
         "Weekend Rate: $10.00"
)

mlmcc
0
 
John-S PretoriusTechnical Service Manager, Mid-AtlanticAuthor Commented:
Thank you so much, great work as always.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.