I have a table called "Employee_Data_tbl" which has the following fields: [EmpID], [Employee], [StartDate], and [DueDate]. I have a form called "Employee_Form" which has a couple listbox and which have their visible property set to false.
What i am trying to do here is have the below code search the "Employee_Data_tbl" and If today's date is "equal" to or "greater" than [StartDate] and today's Date is "Less" than [DueDate] then set the visible property to "true" for Listbox190. Basically, if today's date falls between "StartDate and "DueDate" then show List190, otherwise if it is outside these two date the listbox190 is false. Then If, todays date is equal to or greater than the [DueDate] set the visible property of List201 to True.
This is what I have but it's not working. This code set on the "On Current" event of the form.
[blue]'If Date >= "Me!StartDate" < "Me!DueDate" Then
Me!List190.Visible = True
Else
Me!List190.Visible = False
ElseIf "Me!DueDate" > Date() Then
Me!List201.Visible = True
Else
' Me!List201.Visible = False
End If
End Sub[/blue]
As always, any help very much appreciated..
What i am trying to do here is have the below code search the "Employee_Data_tbl" and If today's date is "equal" to or "greater" than [StartDate] and today's Date is "Less" than [DueDate] then set the visible property to "true" for Listbox190. Basically, if today's date falls between "StartDate and "DueDate" then show List190, otherwise if it is outside these two date the listbox190 is false. Then If, todays date is equal to or greater than the [DueDate] set the visible property of List201 to True.
This is what I have but it's not working. This code set on the "On Current" event of the form.
[blue]'If Date >= "Me!StartDate" < "Me!DueDate" Then
Me!List190.Visible = True
Else
Me!List190.Visible = False
ElseIf "Me!DueDate" > Date() Then
Me!List201.Visible = True
Else
' Me!List201.Visible = False
End If
End Sub[/blue]
As always, any help very much appreciated..