Relationships

N

Nikki

I have done this before a while ago but I must be missing a setting
somewhere. Hopefully this can be answered easily.

I have 2 tables one for orders and one that just includes the 5 departments
( and their PO# and dept heads etc..) that make orders. I want to make a
form with a subform that when I enter a department name I get everything from
the orders table that they ordered.

I have a field called Dept_ID in both tables. I have setup a relationship
and whenever I try to add a new entry I get an Automation warning. If I set
the fieldMaster and Child property to the Department name and not the ID then
I can enter data but the departments are repeated over and over instead.

This may be something you have to see or it may sound familiar right away.
Thanks for the help!!
 
J

John Vinson

I have done this before a while ago but I must be missing a setting
somewhere. Hopefully this can be answered easily.

I don't think it's the settings: I suspect it's the table design.
I have 2 tables one for orders and one that just includes the 5 departments
( and their PO# and dept heads etc..) that make orders. I want to make a
form with a subform that when I enter a department name I get everything from
the orders table that they ordered.

I have a field called Dept_ID in both tables. I have setup a relationship
and whenever I try to add a new entry I get an Automation warning.

What are the datatypes of the Dept_ID?
If I set
the fieldMaster and Child property to the Department name and not the ID then
I can enter data but the departments are repeated over and over instead.

The orders table should have ONLY the Dept_ID field - not the
department name. Again... what are the specific field names and types?
Are any of them Lookup fields? If so be aware that the Lookup feature
*CONCEALS* the actual content of your table, and can cause this kind
of confusion!

John W. Vinson[MVP]
 
N

Nikki

The data_ID fields are Number and Autonumber. I did have a lookup so I got
rid of it. I am still getting this message.

The object doesn't contain the Automation object "Orders" (my table)
You tried to run a Visual basic procedure to set a property or method for an
object. However, the component doesn't make the property or method available
for automation operations.

Check the component's documentation for information on the properties and
methods it makes available for Automation operations.

Thanks
 
M

matkivskij

Nikki said:
The data_ID fields are Number and Autonumber. I did have a lookup so I
got
rid of it. I am still getting this message.

The object doesn't contain the Automation object "Orders" (my table)
You tried to run a Visual basic procedure to set a property or method for
an
object. However, the component doesn't make the property or method
available
for automation operations.

Check the component's documentation for information on the properties and
methods it makes available for Automation operations.

Thanks
 
J

John Vinson

The data_ID fields are Number and Autonumber. I did have a lookup so I got
rid of it. I am still getting this message.

The object doesn't contain the Automation object "Orders" (my table)
You tried to run a Visual basic procedure to set a property or method for an
object. However, the component doesn't make the property or method available
for automation operations.

Check the component's documentation for information on the properties and
methods it makes available for Automation operations.

Thanks

Please post your actual code.


John W. Vinson[MVP]
 

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