Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Automatically calulate Vacation time due to a table

Status
Not open for further replies.

rodm

Technical User
Mar 12, 2002
3
US
What type of formular would you use to add time additional time to accured vacation time. For Example a person gets 10 hours to vacation time on the aniversary date ever 30 days.

Hire Date May 5, 2000 and gets 10 hours each month on are after the 5th of each month.

Thank you
 
Date/time in Ms. Access is just a double. There are a number of functions to add date tyoe info - but these are just convient shorthand for the underlying process of refering to "Days" as the integer portion of the double, and using the fractional part to refer to the time. Ms. Access haas NO actual time type variable, so all uses of time alone are some type of "Kludge". You either carray along a "Day/Date" thing which is some ridiculous value, or just rely on you ability to manipulate the info youself.

Since the time portion is just 1.0 = 24 hours, 10 hours = 10/24 = 5/12 = 0.4166667 of a day, so you can just add this as a constant to your accumulated vacation on any occassion. As the time accrues, you will want to display it in a more useful format than is handily available. In general, take the accrued value * 24 to get the hours (and fractions of an hour. Obviously, many other display formats are possible, this is just to give you the concept.


MichaelRed
redmsp@erols.com

There is never time to do it right but there is always time to do it over
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top