M
mark r
I seem to be creating new records in my maintable when I
donot intend to when I click on a nested subform which
contains a field from my mainform/maintable.
I think the problem is with master field links and child
links that are out of sync
I know I can eliminate the problem one of two ways.
1) by removing the nested subform.
2) remove the field that is causing the problem and put it
into table4.
But for some reasons, I would like not to do either.
I have a mainform for maintable.
It has a command form which opens a subform for table4.
They both have ID as autonumber primary key. One to one
relationship, referential integrity /cascade delete.
subform for table4 is cycle:current record.
I have no problem moving to different records and creating
or updating the correct corresponding records between the
two tables.
The problem arises when I try to enter data in a subform
that is nested in the subofrmtable4.
That nestedsubform has only two fields and they from the
original maintable. I had originally placed these fields
in my maintable. much much later on, I created another
table, since my maintable was getting too big, for more
similar data to these two fields. one to one relationship,
done for table size reasons.... but never placed the first
two fields into the new table. If I move the two fields
now, I am thinking that many queries and reports, etc will
get messed up.
So when I click commandbutton to open subfomrtable4 and
then click on the nested subform, I accidentally create a
new record in maintable instead of updating the data in
the established record.
Mainform displays data for..........Maintable record 25
subformtable4 displays data for.....table4 record 25
if I click a field in nestedsubform
it tries to create a record for.....maintable record 38
Is there a way to make the nested subform "cycle" and
correspond to the
same record ID as the other two forms?
donot intend to when I click on a nested subform which
contains a field from my mainform/maintable.
I think the problem is with master field links and child
links that are out of sync
I know I can eliminate the problem one of two ways.
1) by removing the nested subform.
2) remove the field that is causing the problem and put it
into table4.
But for some reasons, I would like not to do either.
I have a mainform for maintable.
It has a command form which opens a subform for table4.
They both have ID as autonumber primary key. One to one
relationship, referential integrity /cascade delete.
subform for table4 is cycle:current record.
I have no problem moving to different records and creating
or updating the correct corresponding records between the
two tables.
The problem arises when I try to enter data in a subform
that is nested in the subofrmtable4.
That nestedsubform has only two fields and they from the
original maintable. I had originally placed these fields
in my maintable. much much later on, I created another
table, since my maintable was getting too big, for more
similar data to these two fields. one to one relationship,
done for table size reasons.... but never placed the first
two fields into the new table. If I move the two fields
now, I am thinking that many queries and reports, etc will
get messed up.
So when I click commandbutton to open subfomrtable4 and
then click on the nested subform, I accidentally create a
new record in maintable instead of updating the data in
the established record.
Mainform displays data for..........Maintable record 25
subformtable4 displays data for.....table4 record 25
if I click a field in nestedsubform
it tries to create a record for.....maintable record 38
Is there a way to make the nested subform "cycle" and
correspond to the
same record ID as the other two forms?