finding a specific date

aman

Registered User.
Local time
Today, 02:26
Joined
Oct 16, 2008
Messages
1,251
Hi guys

How would I go about finding the date that is 5 working days prior to today, starting yesterday? Working days being Monday - Friday, bank holidays aren't important.

Thanks in advance for any assistance!

AMan
 
I don't understand the "starting yesterday" part.
 
Hi Galaxiom

Leave the starting yesterday part. Simply i want to find the date that is 5 working days prior to today?

Thanks
AMan
 
Use the WeekDay function to find the current day of the week as an integer.
Then a Select Case to subtract the appropriate number of days.
 
Galaxiom,i really don't know exactly how to do it as I want to exclude weekends when displaying the date before last 5 working days of current date.Can you please give me the code for this.

Thanks a lot.
Aman
 
Well 5 working days is 'exactly' one normal week, why not substract 7 calander days??

Lookup the DateAdd function in the MS help and take away 7 days...
 
Well 5 working days is 'exactly' one normal week, why not substract 7 calander days??

I nearly posted the same answer and decided it would be too obvious for him to have asked the question. Then I realised that the starting date could be a Sunday and they would have wanted the previous Monday (or Friday a week prior).
 

Users who are viewing this thread

Back
Top Bottom