[AccessD] Re: check weekday

Robert L. Stewart rl_stewart at highstream.net
Wed Dec 3 13:21:42 CST 2003


IIf(Weekday(Now()-3,[vbsaturday]),Now()-4,IIf(Weekday(Now()-3,[vbsunday]),Now()-5,Now()-3))

Watch for line wrap, but that is the shortest
I think I can make it.  ;-)

At 12:00 PM 12/3/2003 -0600, you wrote:
>Date: Wed, 3 Dec 2003 12:30:19 -0500 (EST)
>From: <Oleg_123 at xuppa.com>
>Subject: [AccessD] check weekday
>To: <accessd at databaseadvisors.com>
>Message-ID: <19836.12.3.132.98.1070472619.squirrel at heck.bay9.com>
>Content-Type: text/plain; charset=iso-8859-1
>
>is there a shorter way of doing this ?
>
>dtEdate = Format(Now() - 3, "mm-dd")
>
>If WeekDay(dtEdate, vbSaturday) Then
>     dtEdate = dtEdate - 1
>ElseIf WeekDay(dtEdate, vbSunday) Then
>     dtEdate = dtEdate - 2




More information about the AccessD mailing list