Dave Sharpe
davesharpe2 at cox.net
Fri Feb 27 18:04:40 CST 2004
Christopher- Possibly working with the following You may be able to get where You need to go. Dave Function DayOne() Dim DayNow As Integer Dim Day1 As Variant Dim Day7 As Variant DayNow = Weekday(Now()) Select Case DayNow Case Is = 1 Day1 = Now() Day7 = Now() + 6 Case Is = 2 Day1 = Now() - 1 Day7 = Now() + 5 Case Is = 3 Day1 = Now() - 2 Day7 = Now() + 4 Case Is = 4 Day1 = Now() - 3 Day7 = Now() + 3 Case Is = 5 Day1 = Now() - 4 Day7 = Now() + 2 Case Is = 6 Day1 = Now() - 5 Day7 = Now() + 1 Case Is = 7 Day1 = Now() - 6 Day7 = Now() End Select End Function ----- Original Message ----- From: "Christopher Hawkins" <clh at christopherhawkins.com> To: <accessd at databaseadvisors.com> Sent: Friday, February 27, 2004 6:26 PM Subject: [AccessD] Getting the start and end dates of the current week I need a function that will determine the start and end dates of the current week. I'm hacking around with some code, but I'm not producing enything useful. Surely I'm not the first to have this problem? -Christopher- -- _______________________________________________ AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com