Main form with tabbed subforms Parent Child error (1 Viewer)

Zydeceltico

Registered User.
Local time
Today, 11:08
Joined
Dec 5, 2017
Messages
843
Hi All -

I am trying to make a form that has a tabbed control that contains four subforms.

All of these are based on the same table. In other words - all of the data recorded in the main form and in the four subforms comprises a single record in a single table. The controls on the main form reflect general and global aspects of the table while all of the subforms collect details.

I designed this all this way as I thought it would be good to have the global data visible while collecting the detailed data on the subforms.

I am able to fill out the information in the main form and the subform on the first tab but I get an error message when trying to move to the second tab about primary keys as "they would create duplicate values in index, primary key or relationships."

I've looked at the Parent/Child links for each and yes they do all point to the PK of the table (tblWeldTests).

Maybe there is a better approach than what I am envisioning.

Thank you in advance,

Tim
 

Attachments

  • WeldTestsDB.zip
    98.6 KB · Views: 44

MajP

You've got your good things, and you've got mine.
Local time
Today, 11:08
Joined
May 21, 2018
Messages
8,527
Well those really do not need to be subforms. All the data is coming from one table. You can keep the tabs and group the fields on the tabs, but no need for a subform. All the fields are in the main forms recordsource.
 

Zydeceltico

Registered User.
Local time
Today, 11:08
Joined
Dec 5, 2017
Messages
843
Well those really do not need to be subforms. All the data is coming from one table. You can keep the tabs and group the fields on the tabs, but no need for a subform. All the fields are in the main forms recordsource.


Thank you MajP. Again my inexperience. I didn't understand much about creating tabbed forms - and easy it is. I had assumed that I had to create a form from a table - - (follow my thick logic here) - - I didn't understand that I could open a blank form and "attach/populate" fields from the table to the form.

I have said many, many times on here that I know just enough to be dangerous (or annoying :) - this would be one of those instances. After having figured this out, I feel pretty empowered. LOL

The form in question is frmWeldTest derived from tblWeldTests.

Thanks,

Tim
 

Attachments

  • WeldTestsDB.zip
    107.5 KB · Views: 33

Users who are viewing this thread

Top Bottom