<-- Previous || Up || Next -->

Last Day Of Week Function
Dates Times Class

Public Function LastDayOfWeek( _
    ByVal vDate As Variant _
    ) As Variant

Returns the last day of the week (the Saturday) for the given date.
Returns vDate if it is already the last day of the week.

Examples:
    LastDayOfWeek(#1/12/96#) = #1/13/96#
    LastDayOfWeek(#1/13/96#) = #1/13/96#
    LastDayOfWeek(#1/14/96#) = #1/20/96#
    LastDayOfWeek(#1/20/96#) = #1/20/96#
    LastDayOfWeek(#1/21/96#) = #1/27/96#
See also:
    FirstDayOfWeek Function
    LastDayOfMonth Function
    LastWeekdayOfMonth Function
    LastDayOfWeekInMonth Function
    LastDayOfPeriod Function
vDate: The date used to determine the week whose last day is returned. Function returns Null if vDate is Null or cannot be fixed up to a Date.
v2.0 Addition: This function is new to this version of Entisoft Tools.

Copyright 1996-1999 Entisoft
Entisoft Tools is a trademark of Entisoft.