Making a form based on a query with a subform?

NewShoes

Registered User.
Local time
Yesterday, 19:02
Joined
Aug 1, 2009
Messages
223
Hi all,

Tricky one this.....

I would like to create a form that displayes records based on a query. However, it becomes a little more difficult when I need the top of the form to display employee info (name, ID etc) but have a Subform showing records of absences relating to that employee BUT only absences that fall within 2 dates that I have set.

Can this be easily done?

Thanks in advance!
NS
 
Enter the dates and employeeID in controls on the main form and include these controls in the subform record source query.

Another way is to use the Link Master Fields and Link Child Fields properties in the subform control to limit to the chosen employeeID.
 
Enter the dates and employeeID in controls on the main form and include these controls in the subform record source query.

Another way is to use the Link Master Fields and Link Child Fields properties in the subform control to limit to the chosen employeeID.


Hi, thanks for the quick reply!

By controls, do you u mean text boxes? How would I go about including these controls in the subfrom record source query?

Many thanks,
NS
 
Textboxes, comboboxes, listboxes etc are all called controls.

Referring to controls from various places on a form.
http://www.mvps.org/access/forms/frm0031.htm

Note however you cannot use Me! in the SQL so use the full reference.
Forms!formname.......etc
 
Textboxes, comboboxes, listboxes etc are all called controls.

Referring to controls from various places on a form.
http://www.mvps.org/access/forms/frm0031.htm

Note however you cannot use Me! in the SQL so use the full reference.
Forms!formname.......etc

Many thanks for your reply.

I'm struggling with this. Do you know of an example I can download and see how it all works?

Thanks,
NS
 

Users who are viewing this thread

Back
Top Bottom