Problem with table in subordinate form

andrey_anikin

Registered User.
Local time
Today, 16:53
Joined
Jan 3, 2008
Messages
31
Hi everyone,

I have a "split form" in Access 2007 (where data is shown both in a table and in a set of text fields), and I'm trying to build in a subordinate form showing data from another table (linked to the first one as "one-to-many" with "one" on the side of the 1st table). It all works fine but for the fact that I always get a side effect: as soon as I add a datasource (the 2nd table) into the subordinate form, every record in the 1st table turns from a simple line into a "grouped" entry - i.e. I get records from the 2nd table visually added to records from the 1st one according to the keyfield value (though nothing actually happens to the tables in the DB, just their representation on the form).

Any idea why this happens and how it can be fixed? Thanks in advance :)
 
Have further investigated the problem. Part of what I said earlier is not true: when I create a sub form having as the record source a table or a query somehow linked to the main table, I get both the main table and its representation on the form "upgraded" - each line in the main table gets its share of lines from the linked table/query. Have found a cure, though: now I have a set of text controls and a table on the form, both linked to one and the same table but not related to each other (have to syncronize them manually, though; so far have found just one way - to give both of them an equal record set at the time of the form opening... the same doesn't work if I use the Form Load event... wonder why); so nothing bad happens when I add a sub form with a linked table/query.
 
Access should handle the parent/child relationships automatically so that the form and subform are always synchronised. Did you use the subform wizard?
 
Access should handle the parent/child relationships automatically so that the form and subform are always synchronised.

Exactly - and this seems to be somehow connected with the "subtable" issue I had. I got the problem fixed only when I deployed independent controls (a set of text controls plus a subform with a table) linked to one and the same record source.
 

Users who are viewing this thread

Back
Top Bottom