NearestWeekdayAfter Function

Description:
The date which corresponds to the nearest weekday on or after the source date, where:
  • 1= Sunday
  • 2= Monday
  • 3= Tuesday
  • 4= Wednesday
  • 5= Thursday
  • 6= Friday
  • 7= Saturday
Returns:
Date
Parameters:
Parameter
Data Type
Description
1
Date
The source date.
2
Whole Number
The day of the week in the range 1 (Sunday) to 7 (Saturday).
Examples:
When using functions inside a field, remember the field brackets:
{NearestWeekDayAfter(ClosingDate, #)}
Expression
Result
NearestWeekdayAfter( Date( 2000, 2, 29 ), 2 )
Date( 2000, 3,6 )
NearestWeekdayAfter( Date( 2000, 2, 29 ), 3 )
Date( 2000, 2, 29 )
NearestWeekdayAfter( Date( 2000, 2, 29 ), 4 )
Date( 2000, 3, 1 )