Need Help ASAP!!!!!

G

Guest

I have a database where in the main table I enter in general information
pertaining to a company, like their coproprate headquarters etc..In the
second form I enter in Additional company information like Sub offices and
contacts.
I have created both forms, and have the relationship between the company
field in each table. But When I choose a company from the drop down box in
the first form, and the click on the tab for the second form, every entry is
showing from that table. How do I get it to be specific to the company I
choose from the first page.

Somebody Please Help FAST!
 
G

Guest

Open the form/dubform in design view. Click on menu VIEW - Properties.

Click in the upper left corner of the subform. Check the Link Child Fields &
Link Master Fields to make sure the property is set to the field in the
relationship between the company in the tables.
 
G

Guest

Karl,
Thanks for the advice. I have done this as well. Maybe I am not
understanding the link between the Child and master fields. I have set
company up as the master field in the main table and the child field is also
the child field in the subform. Is this correct, or could this be causing my
problem.


Thanks
 
G

Guest

Your main (company) table should have a primary key field. Most folks use an
atuonumber field. The second table containing the additional company
information like Sub offices and contacts has a field with the number
matching that in the main table. Then set a relationship of one-to-many from
the main table to the second table using the autonumber field and number
field.

This is the field you would use as master/child links between main form and
subform.

The main form would use the main table as record source - I always like to
use a query between the table and the form as I can easily set criteria like
not pulling old companies, etc.

The subform would pull data from the second table through a query - criteria
to not display old contacts, etc.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top