Access Ver 2.0 Adding days to a date to give target date excluding weekends?

M

michael.nilsen

Hi Everyone,

Not sure if i'm posting in the right spot so sorry if its not, please
direct me to the correct location :)

I have three fields in a form, [quote accepted], [days to results] and
[target date]. I need to calculate the target date by adding the [quote
accepted] and [days to results] together but i want to exclude the
weekends as [days to results] is only working days.

Example

Quote accepted date: 16/11/2006

Days to result: 20

Target Date: 14/12/2006

Also there can be time where the information will be missing so
therefore it will have to handle null values ect

I have no preference over code or macro, which ever is better for this
application.
 
D

Douglas J. Steele

Recognizing that there will be 2 weekend days for every 5 working days, try
adding 28 days to the accepted date to get the target date.

For more sophistication, take a look at
http://www.mvps.org/access/datetime/date0012.htm at "The Access Web". (If
you are actually using Access 2.0, as your subject line indicates, you'll
have to change all references to the Date data type to Variant, as I seem to
recall that Access 2.0 didn't have a Date data type)

--
Doug Steele, Microsoft Access MVP

(no private e-mails, please)


Hi Everyone,

Not sure if i'm posting in the right spot so sorry if its not, please
direct me to the correct location :)

I have three fields in a form, [quote accepted], [days to results] and
[target date]. I need to calculate the target date by adding the [quote
accepted] and [days to results] together but i want to exclude the
weekends as [days to results] is only working days.

Example

Quote accepted date: 16/11/2006

Days to result: 20

Target Date: 14/12/2006

Also there can be time where the information will be missing so
therefore it will have to handle null values ect

I have no preference over code or macro, which ever is better for this
application.
 
Top