okay, SS and Doug, you both did me one better (and Al, too), but i didn't
find GetBusinessDay() as a built in function in A97 or A2000-2003. share?
btw, SS, i've seen you post in these groups a lot, so i figured from your
skill level that you already knew the "don't store calculated data" rule.
but sometimes i think of other folks reading threads who may not be as
experienced, and speak to them, too. hope i didn't offend!
Secret Squirrel said:
Hi Tina,
I acutally figured it out. Here's what I used to calculate the first
business day of the year the employee was hired.
=GetBusinessDay(DateSerial(Format([StartDate],"yyyy")+0,1,1),1)
And yes I meant to say control and not field.
tina said:
i suppose you could write a function to take the year of the hire date, add
1/2, so it's 1/1/xx, then run a loop to check for day of week and bump the
date by one day as needed until the check returns a weekday.
and btw, i assume when you said "field" in your post, you meant "control". a
hire date is hard data, of course, but the first business day of the same
year is a calculated value, and shouldn't be stored as hard data in a table
unless you have a sound business reason for doing so.
hth
message I have a field on my form called "HireDate". I need to add another field
that
calculates the first business day of the year that the hire date is in.
For
example if the hire date is 03/01/04 I need this new field to be 01/02/04.
How would I create this calculation?