relation problem between Mainform-Subform?

M

mezzanine1974

Suppose that there are two related tables by just one field. Relation
type is one-to-many relation: enforce referantial integrity enabled,
Cascade Update disabled, Cascade Delete disabled.
Say that Table1 has ONE, Table2 has MANY side of the relation.
My target is to creat a columnar form by table1 and insert a tabular
subform by table2. So that, link child fields and link master fields
are to be set on the field by which relation is established.
By using navigation buttons, i can switch to next record on the Table1
and all related itemsin the Table2 automatically to be seen in the
tabular subform. So, I can edit any value in the tabular subform.
To make this process faster, I changed the edit box in the Main form
(by which relation is established) into ComboBox, so I can get the
desired record faster. However, I CAN NOT edit subform because of such
error message "The record can not be deleted or changed because
Table2 includes related records".
Is there a way to swich another record by ComboBox instead of
navigation button?
I need to access the Table2 record as fas as possible, by using the
Table1.

Thanks
 
G

Guest

You can use a combobox, just make it unbound. Set the recordset to a query
for table1. You can use the wizard for this...

hth
 
M

mezzanine1974

Maurice,
You are not talking about a query result for Table2, right? I mean,
can i edit records in the Subform (Table2) which will be selected by
unbound ComboBox?
 
M

mezzanine1974

Thanks Marica!
I understand what you mean.. i have already prepared such form by
myself by using your clues.
 

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