B
Bruce
This is just a sketch. If details are needed, I will
provide them, but I don't want to litter the posting with
unnecessary information.
I havd a parameter query as the source for a report. The
report is grouped by employee name, with a separate page
for each employee. Employee name is one of the
parameters. The other is date.
I am using a combo box (cboSelectName) on a form (frmNames)
for the employee name. The row source of the combo box is
a query. The bound column is EmployeeID, which is the
primary key from the Employees table. The criteria for
EmployeeID in the query on which the report is based is
[Forms]![frmNames]![cboSelectName]. The criteria for date
is Between [Start] and [End]. That is OK as long as I
select one name and a date range, but I also would like to
select all employees within a date range. I tried making
the Or part of the criteria for Employee ID Like
[EmployeesTable]![EmployeeID] & "*", with the Or part of
the Date field the same as for the criteria. Similarly, I
made the criteria for date Like [Date] & "*". I did that
twice, once with each of the previously mentioned criteria
for EmployeeID. There is one criteria and three Or
statements.
Question: When I have a criteria change in one field
(e.g. select one employee or select all employees) and the
same criteria (date range) in both cases in another field,
do I still need the Or in the date field on both the
Criteria line and the Or line?
This is driving me nuts, because when I first put it
together it worked, but later in the day (after I had
added some records), it no longer worked. I could still
select a date range, but could not narrow it down to one
employee. Can't figure why it stopped working, or for
that matter if I need to do something different. Any
ideas? Help is, as usual, no real help.
provide them, but I don't want to litter the posting with
unnecessary information.
I havd a parameter query as the source for a report. The
report is grouped by employee name, with a separate page
for each employee. Employee name is one of the
parameters. The other is date.
I am using a combo box (cboSelectName) on a form (frmNames)
for the employee name. The row source of the combo box is
a query. The bound column is EmployeeID, which is the
primary key from the Employees table. The criteria for
EmployeeID in the query on which the report is based is
[Forms]![frmNames]![cboSelectName]. The criteria for date
is Between [Start] and [End]. That is OK as long as I
select one name and a date range, but I also would like to
select all employees within a date range. I tried making
the Or part of the criteria for Employee ID Like
[EmployeesTable]![EmployeeID] & "*", with the Or part of
the Date field the same as for the criteria. Similarly, I
made the criteria for date Like [Date] & "*". I did that
twice, once with each of the previously mentioned criteria
for EmployeeID. There is one criteria and three Or
statements.
Question: When I have a criteria change in one field
(e.g. select one employee or select all employees) and the
same criteria (date range) in both cases in another field,
do I still need the Or in the date field on both the
Criteria line and the Or line?
This is driving me nuts, because when I first put it
together it worked, but later in the day (after I had
added some records), it no longer worked. I could still
select a date range, but could not narrow it down to one
employee. Can't figure why it stopped working, or for
that matter if I need to do something different. Any
ideas? Help is, as usual, no real help.