I have an old database that worked perfectly fine however I had to modify it as there has been a slight change to the data that is being imported. The problem is after I made the changes the new database did not work as it should. I have created two stripped down versions of the databases and have attached them to this post. Could someone compare the two databases and let me know where I am going wrong. Both the databases automatically open a form, from this form select Art&Design from the Subjects combo box to see the problem. As shown in 'working.mdb' after selecting a subject a subform should appear and allow you to select different names which change the grades listed, and also let you type in a comment.
From what I can tell there isn't a problem with Subj_Art&Design_qry. Both queries are joined exactly the same way, the only differences are a few changed column names and 1 column that has been removed. The underlying tables have similar data type layouts so I don't think the problem is due to incompatible data.
I have just tried adding a record with SubjStuRecId as 0. This worked in that it brought up the subform when Art&Design is selected, however when you change the surname combo box the subform disappears again. This way it would only work if I entered the SubjStuRecID's for every name. This was not necessary in the working database which automatically put the correct number in the SubjStuRecID field when the relevant name was selected on the mainreport form.