Elapsed days

  • Thread starter Thread starter twalsh
  • Start date Start date
T

twalsh

I have a field in a table (tblProfile) showing Date of Hire (DOH) for
employees and a Form showing the info in the table.

I want a text box that shows the number of days since the date of Hire, the
text box doesnt need to be bound to any fields, just display the number of
days. The eventual goal is to use conditional formatting to change the
apperance of the form for employees under 90 days to "red flag" them for
special attention.
 
I have a field in a table (tblProfile) showing Date of Hire (DOH) for
employees and a Form showing the info in the table.

I want a text box that shows the number of days since the date of Hire, the
text box doesnt need to be bound to any fields, just display the number of
days. The eventual goal is to use conditional formatting to change the
apperance of the form for employees under 90 days to "red flag" them for
special attention.

To show the number of days since hire:
Using an Unbound control on your form:
=DateDiff("d",[DOH],Date())

or you can simply use:
=Date()-[DOH]

However, if you just want to show the [DOH] in a different color on
the form, all you need do is use Conditional Formatting.

Select the control. Clisk on Format + Conditional Formatting
Set Condition1 to
Expression Is
In the next box write
Date()-[DOH] <=60
Set the font or Back color to whatever colors you wish.
 
Thanks that worked beautifully.

Now anyone have any suggestions on how to make it terribly obvious that an
employee has been here under 90 days?
 
Back
Top