I give up!!!!!!!!!!!!

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Ok. Here is my situation.
This is the result that I want. I have a query that lists my department's
overtime. It is a year long list with the field [Week Ending] so I can tell
what week to use on the report. I have also created the Form to display any
given week's data.

I want a Combo box to find an employee then populate a second Combo box with
the weeks they had overtime. Once both combo boxes are populated I want to
filter the associated form to display That employee on That week's data.

Thanks

Joe c
 
This is a typical cascading combo situation.
You Employee combo is simple enough. It just needs to have a row source
that will list all the employees.
You OvertimeWeeks combo needs a row source that includes all the weeks and
can be filtered by the value in the employee combo. To get the correct list,
you need to requery the Overtimeweeks combo in the After Update event of the
Employee combo.
Your form's record source needs to be a query that can be filtered on the
values in both combos. To populate the form, requery the form in the after
update event of the Overtimeweeks combo.
 
Thanks for your response.

Are you suggesting that there are three different things, a table for names,
a table for week ending dates and a query?

JC

Klatuu said:
This is a typical cascading combo situation.
You Employee combo is simple enough. It just needs to have a row source
that will list all the employees.
You OvertimeWeeks combo needs a row source that includes all the weeks and
can be filtered by the value in the employee combo. To get the correct list,
you need to requery the Overtimeweeks combo in the After Update event of the
Employee combo.
Your form's record source needs to be a query that can be filtered on the
values in both combos. To populate the form, requery the form in the after
update event of the Overtimeweeks combo.

Joe C said:
Ok. Here is my situation.
This is the result that I want. I have a query that lists my department's
overtime. It is a year long list with the field [Week Ending] so I can tell
what week to use on the report. I have also created the Form to display any
given week's data.

I want a Combo box to find an employee then populate a second Combo box with
the weeks they had overtime. Once both combo boxes are populated I want to
filter the associated form to display That employee on That week's data.

Thanks

Joe c
 
Not necessarily. It depends on how your data is currently structured. I
assume you have a table with all the employees. For your employee combo, you
need a query that will return the employee name and probably employee number.
What fields you use will depend on what table tells you whether they had
overtime in a given week and how you relate that table to the employee.

For the overtimeweeks combo, you will need a query that will return whatever
identifies a week with overtime and any other fields you need. It will need
to include the employee identifier so you can filter it based on the employee
combo.

For your form's record source, you need a query that returns the fields from
the table that has the overtime data in it. It needs to include the employee
identifier and week so you can filter it based on the employee and week
selected.


Joe C said:
Thanks for your response.

Are you suggesting that there are three different things, a table for names,
a table for week ending dates and a query?

JC

Klatuu said:
This is a typical cascading combo situation.
You Employee combo is simple enough. It just needs to have a row source
that will list all the employees.
You OvertimeWeeks combo needs a row source that includes all the weeks and
can be filtered by the value in the employee combo. To get the correct list,
you need to requery the Overtimeweeks combo in the After Update event of the
Employee combo.
Your form's record source needs to be a query that can be filtered on the
values in both combos. To populate the form, requery the form in the after
update event of the Overtimeweeks combo.

Joe C said:
Ok. Here is my situation.
This is the result that I want. I have a query that lists my department's
overtime. It is a year long list with the field [Week Ending] so I can tell
what week to use on the report. I have also created the Form to display any
given week's data.

I want a Combo box to find an employee then populate a second Combo box with
the weeks they had overtime. Once both combo boxes are populated I want to
filter the associated form to display That employee on That week's data.

Thanks

Joe c
 
Klatuu,

Can you use the same query for the overtime combo and the form record source?
JC

Klatuu said:
Not necessarily. It depends on how your data is currently structured. I
assume you have a table with all the employees. For your employee combo, you
need a query that will return the employee name and probably employee number.
What fields you use will depend on what table tells you whether they had
overtime in a given week and how you relate that table to the employee.

For the overtimeweeks combo, you will need a query that will return whatever
identifies a week with overtime and any other fields you need. It will need
to include the employee identifier so you can filter it based on the employee
combo.

For your form's record source, you need a query that returns the fields from
the table that has the overtime data in it. It needs to include the employee
identifier and week so you can filter it based on the employee and week
selected.


Joe C said:
Thanks for your response.

Are you suggesting that there are three different things, a table for names,
a table for week ending dates and a query?

JC

Klatuu said:
This is a typical cascading combo situation.
You Employee combo is simple enough. It just needs to have a row source
that will list all the employees.
You OvertimeWeeks combo needs a row source that includes all the weeks and
can be filtered by the value in the employee combo. To get the correct list,
you need to requery the Overtimeweeks combo in the After Update event of the
Employee combo.
Your form's record source needs to be a query that can be filtered on the
values in both combos. To populate the form, requery the form in the after
update event of the Overtimeweeks combo.

:

Ok. Here is my situation.
This is the result that I want. I have a query that lists my department's
overtime. It is a year long list with the field [Week Ending] so I can tell
what week to use on the report. I have also created the Form to display any
given week's data.

I want a Combo box to find an employee then populate a second Combo box with
the weeks they had overtime. Once both combo boxes are populated I want to
filter the associated form to display That employee on That week's data.

Thanks

Joe c
 
yes

Joe C said:
Klatuu,

Can you use the same query for the overtime combo and the form record source?
JC

Klatuu said:
Not necessarily. It depends on how your data is currently structured. I
assume you have a table with all the employees. For your employee combo, you
need a query that will return the employee name and probably employee number.
What fields you use will depend on what table tells you whether they had
overtime in a given week and how you relate that table to the employee.

For the overtimeweeks combo, you will need a query that will return whatever
identifies a week with overtime and any other fields you need. It will need
to include the employee identifier so you can filter it based on the employee
combo.

For your form's record source, you need a query that returns the fields from
the table that has the overtime data in it. It needs to include the employee
identifier and week so you can filter it based on the employee and week
selected.


Joe C said:
Thanks for your response.

Are you suggesting that there are three different things, a table for names,
a table for week ending dates and a query?

JC

:

This is a typical cascading combo situation.
You Employee combo is simple enough. It just needs to have a row source
that will list all the employees.
You OvertimeWeeks combo needs a row source that includes all the weeks and
can be filtered by the value in the employee combo. To get the correct list,
you need to requery the Overtimeweeks combo in the After Update event of the
Employee combo.
Your form's record source needs to be a query that can be filtered on the
values in both combos. To populate the form, requery the form in the after
update event of the Overtimeweeks combo.

:

Ok. Here is my situation.
This is the result that I want. I have a query that lists my department's
overtime. It is a year long list with the field [Week Ending] so I can tell
what week to use on the report. I have also created the Form to display any
given week's data.

I want a Combo box to find an employee then populate a second Combo box with
the weeks they had overtime. Once both combo boxes are populated I want to
filter the associated form to display That employee on That week's data.

Thanks

Joe c
 
Back
Top