If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Fomula in a Text Box
I have form for employees, on this form there is an is a field in which the date of the employees induction is stored.
I created a text box and added the formula below to highlight if the employee needed a review induction. ie if the employee had been there for more than 1 year, then a review needs to be done. I want this to display on the form because it will only be looked at if a casual employee is going permanent BUT if I put the "greater than" sign one way they all come up the same and if I reverse it they all come up the other remark. Waht have I done wrong.... =iif([Induction Date](now()-365),"A review induction must be completed","A review induction is not necessary") All help much appreciated. Thanks |
#2
|
|||
|
|||
Fomula in a Text Box
PJ,
Simply: ="A review induction " & IIf(DateAdd("yyyy", 1, [Induction Date]) Date(), "must be completed.", "is not necessary.") However, there appears to be no way to include employees who were inducted more than a year ago, but have not had their induction review yet. I suggest adding a field to indicate the date an induction review was conducted. Then you could include that in your formula. ="A review induction " & IIf(DateAdd("yyyy", 1, [Induction Date]) = Date(), "must be completed.", IIf([Review Date] Is Null, "is overdue.", "is not necessary.")) Regards, Graham R Seach Microsoft Access MVP Sydney, Australia Microsoft Access 2003 VBA Programmer's Reference http://www.wiley.com/WileyCDA/WileyT...764559036.html "PJ" wrote in message ... I have form for employees, on this form there is an is a field in which the date of the employees induction is stored. I created a text box and added the formula below to highlight if the employee needed a review induction. ie if the employee had been there for more than 1 year, then a review needs to be done. I want this to display on the form because it will only be looked at if a casual employee is going permanent BUT if I put the "greater than" sign one way they all come up the same and if I reverse it they all come up the other remark. Waht have I done wrong.... =iif([Induction Date](now()-365),"A review induction must be completed","A review induction is not necessary") All help much appreciated. Thanks |
Thread Tools | |
Display Modes | |
|
|