Chelsea Siefert
Chelsea Siefert

Reputation: 31

MS Access 2010 Error: You Cannot Add or Change a Record Because Related Record is Required in 'Table'

I have two related tables, 'Submittals' and 'SubmittalType'. I have related the 'SubType' fields in both as a one ('SubmittalType') to many ('Submittals') relationship. I have created a form where users can enter all required information for new submittals. On this form, I have created a combo box for 'SubType' that lists the records from the 'SubmittalType' table as the only choices from which a user can select. On the "data" tab in the properties sheet, the Control Source is listed as 'SubType' (from the Submittals table) and the Row Source is listed as:

SELECT [SubmittalType].[ID], [SubmittalType].[SubType] FROM SubmittalType;

When I test the form, entering all required information and selecting one of the options from the SubType combo box, and attempt to close the form I get the error: "You cannot add or change a record because a related record is required in table 'SubmittalType'." It seems to me that the related record is already in the table, otherwise I would not be able to select it in the combo box.

I am teaching myself Access 2010 as I go along and cannot figure out what could be going wrong. Any help you can provide (and in as simple language as possible) would be greatly appreciated.

Upvotes: 0

Views: 522

Answers (1)

Chelsea Siefert
Chelsea Siefert

Reputation: 31

The Bound Column property of the combo box is set to store the wrong field from the 'SubmittalType' table in the 'Submittals' table 'SubType' field. The Bound Column property is set as "1" where it should be set as "2" as the second column in the 'SubmittalType' table is the one which satisfies the relationship.

Upvotes: 1

Related Questions