October 14, 201015 yr I have a personell management file that keep track of school faculty and staff. I have a field on the form called hire date. I have another field called years of service that show how many years the member has been with the school. I want that years of service field to relate to the hire date and automatically update the number of years of service so i dont have to do so manually. How do I go about doing so? Thanks For The Help!! Erik
October 16, 201015 yr Your Years Of Service field should be a calculation (result is date) as: Let ( [ now = Get ( CurrentDate ) ; this = Date ( Month ( HireDate ) ; Day ( HireDate ) ; Year ( now ) ) ] ; Year ( now ) - Year ( HireDate ) - ( now < this ) ) // END LET When you create this calculation (and you are still in the calculation dialog, go into Storage Options and select the checkbox 'do not store calculation results.' This is required so the calculation updates every time it is accessed.
October 16, 201015 yr Your Years Of Service field should be a calculation (result is date) Your fingers slipped: result type should be Number.
October 16, 201015 yr Thank you but I think it was that my mind slipped. BTW, someone could also use Ray's trickery calc for the test whether full year has lapsed, which is if IIRC: Month ( now ) + Day ( now ) / 100 < Month ( HireDate ) + Day ( HireDate ) [color:red]/ 100 Edited October 16, 201015 yr by Guest forgot red
Create an account or sign in to comment