D
Duncs
I have a form that contains a ComboBox control, which displays the
following information:
Project Description
Project Code
Valid Until Date
The table definition is as follows:
tblProjects.fldProjectDescription
tblProjects.fldProjectID
tblProjects.fldValidUntilDate
What I want to happen, is when a project reaches its ValidUntil date,
it should no longer appear in the drop-down list. However, where an
employee has created a valid entry in the past, the project description
should still be displayed.
I have created my Combo Control as follows:
ControlSource tblTimeSheet.fldProjectID
RowSource SELECT tblProjects.ProjectDescription,
tblProjects.fldProjectID,
tblProjects.fldValidUntilDate
FROM tblProjects
WHERE tblProjects.fldValidUntilDate > Date()
ORDER BY tblProjects.fldProjectID;
BoundColumn 2
With this setup, the drop-down does indeed restrict the entries to
those with a ValidUntil date in the future. However, it does not
display an entry in the ComboBox control for those projects that have
passed their ValidUntil date. For example, if "Project Alpha" has a
Valid Until date of 1st June, 2006, "Project Alpha" would not appear in
the drop-down. However, if any employee has worked on "Project Alpha"
in the month of May, the project details will not be displayed.
Can anyone suggest a way of doing what I want the control to do?
Many thanks & regards
Duncs
following information:
Project Description
Project Code
Valid Until Date
The table definition is as follows:
tblProjects.fldProjectDescription
tblProjects.fldProjectID
tblProjects.fldValidUntilDate
What I want to happen, is when a project reaches its ValidUntil date,
it should no longer appear in the drop-down list. However, where an
employee has created a valid entry in the past, the project description
should still be displayed.
I have created my Combo Control as follows:
ControlSource tblTimeSheet.fldProjectID
RowSource SELECT tblProjects.ProjectDescription,
tblProjects.fldProjectID,
tblProjects.fldValidUntilDate
FROM tblProjects
WHERE tblProjects.fldValidUntilDate > Date()
ORDER BY tblProjects.fldProjectID;
BoundColumn 2
With this setup, the drop-down does indeed restrict the entries to
those with a ValidUntil date in the future. However, it does not
display an entry in the ComboBox control for those projects that have
passed their ValidUntil date. For example, if "Project Alpha" has a
Valid Until date of 1st June, 2006, "Project Alpha" would not appear in
the drop-down. However, if any employee has worked on "Project Alpha"
in the month of May, the project details will not be displayed.
Can anyone suggest a way of doing what I want the control to do?
Many thanks & regards
Duncs