Edit week length

  • 0
  • 1
  • Question
  • Updated 3 months ago
  • Answered
I have a field that calculates Week Of based on the date that someone enters for each record. I have set Sunday to be the displayed date for the Week Of field using the formula:

PrevDayofWeek([Date], 0)

The problem I'm running into is if someone enters a record in on Sunday, it relates it to the previous Sunday instead of the current Sunday. This example is what I'm getting:

Date: 9/16/2018
Week Of: 9/9/2018

Week Of should be 9/16, not 9/9 but can't figure out how to change it to show the right Week Of?
Photo of Courtney Rapp

Courtney Rapp

  • 242 Points 100 badge 2x thumb

Posted 3 months ago

  • 0
  • 1
Photo of Everett Patterson

Everett Patterson

  • 762 Points 500 badge 2x thumb
Try this for the WeekOf formula

If(DayOfWeek([Date])=0, [Date], PrevDayOfWeek([Date], 0))

Photo of Courtney Rapp

Courtney Rapp

  • 242 Points 100 badge 2x thumb
Worked like a charm, thank you!