Change the query for LboxEndDate to the following:
SELECT qryBreakScheduleByDate.BDate, qryBreakScheduleByDate.Project,
qryBreakScheduleByDate.SerialNo
FROM qryBreakScheduleByDate
WHERE (((qryBreakScheduleByDate.BDate)>=Format([Forms]![frmSummary]!
[LboxStartDate], "\#mm\/dd\/yyyy\#")))
ORDER BY qryBreakScheduleByDate.BDate;
--
Ken Snell
<MS ACCESS MVP>
http://www.accessmvp.com/KDSnell/
On Nov 15, 9:08 am, "Ken Snell \(MVP\)"
Post the SQL statement of the query that you tried to use, but that
didn't
work. How are you running this query -- from a command button on the
form
that holds the three listboxes? What are the following properties of
each
listbox:
RowSourceType
RowSource (if = name of query or table, give details about
table/query)
BoundColumn
Format
ColumnCount
ColumnWidths
--
Ken Snell
<MS ACCESS MVP>
http://www.accessmvp.com/KDSnell/
I have a query that has 2 columns: Dates and Projects.
I want to view the projects that were done on and between 2 dates..
I had set up a form and put 3 list boxes.
lboxStartDate
lboxEndDate
lboxProjects.
I tried some examples found on the net but could not get it to work
I also was not able to filter the lboxEndDate to be show dates >=
lboxStartDate.
Can I get some help with this?- Hide quoted text -
- Show quoted text -
Ken,
my LboxStartDate has the following SQL:
SELECT DISTINCT qryBreakScheduleByDate.BDate
FROM qryBreakScheduleByDate
ORDER BY qryBreakScheduleByDate.BDate;
and my LboxEndDate has the following:
SELECT qryBreakScheduleByDate.BDate, qryBreakScheduleByDate.Project,
qryBreakScheduleByDate.SerialNo
FROM qryBreakScheduleByDate
WHERE (((qryBreakScheduleByDate.BDate)=[Forms]![frmSummary]!
[LboxStartDate]))
ORDER BY qryBreakScheduleByDate.BDate;
Both are bound to column 1
Currently I have the EndDate Lbox equal to the first box and that
works as written below but I wanted to get only dates >= the
StartDate.
I tried >= but it did not work. I tried adding WHERE >= [Forms]!
[frmSummary]![LboxStartDate] and that gave me the aggregate expression
error.- Hide quoted text -
- Show quoted text -