Share via

Form with Tab Control Subforms link through Combo Box?

Anonymous
2012-05-03T19:51:27+00:00

I've read several of the questions and answers about Master/Child links and linking forms with subforms, but I need to ask this one more time. Sorry, but I used to build these in previous versions of Access, and I'm having a hard time understanding how to do it now that we need to make our Combo Boxes Unbound.

Is the main form based on something, or is it just an Unbound form containing an Unbound Combo Box, and if so, what is the Master/Child link?

I have a form based on a query that has a Tab Control with one sub-form on each of 5 tabs. All subforms have the same Child link of RecID (an autonumber key from the Recipient table). RecID is also a field of the query on which the Parent form is based AND it is the primary field of a combo box with which I planned to select the record that would link all of this data together.

Unfortunately, when I try to enter information into any of the subforms, I am receiving a message box that states "You must enter a value in the 'tRecipMeasurements.RecipFName' field."

I know I have something entered in that field, because it is the first name of the person being selected in the Combo Box, and it's there on the drop-down list.

Any suggestions about what I've done wrong?

I am using Access 2007 on a machine running Windows 7 Professional 64-bit.

Thanks in advance for any help you can give me in understanding why everything is SO different from Access V1.0 thru 2003.

Microsoft 365 and Office | Access | For home | Windows

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments

Answer accepted by question author

Anonymous
2012-05-04T09:04:02+00:00

OK! Slapping myself on the forehead on this one.

I didn't know I could put fields from a single table onto multiple tabs without using sub-formts. The secret was to cut and paste the fields from the main form to the tab control pages, and once I learned how it was really quite easy. No need for Master/Child either.

Thank you for all the help.

Was this answer helpful?

0 comments No comments

Answer accepted by question author

Anonymous
2012-05-04T01:51:26+00:00

It can be very helpful to use the form wizard to create the main form and one of the subforms.

When using the wizard, don't do any formatting - the wizard's forms are just to help you to see where you are going wrong with your form and subform setup.

The wizard will build the form and subform and you can look at the result and compare with the way you set up your forms and see what is going wrong. The wizard will also advise if the main form with subform approach won't work with the tables (queries) you are using.

If that doesn't help you, post back with the tables and relationships associated with this form and 1 of the subforms.

Once you get the main form and subform working for one subform, then it is easy enough to extend by adding more subforms.

Was this answer helpful?

0 comments No comments

2 additional answers

Sort by: Most helpful
  1. Anonymous
    2012-05-04T01:11:03+00:00

    Hi Jeanette,

    Thank you for the suggestion. I did that, and I realize it "should" work, but I'm still getting the same message box about needing to enter a value in the First Name field.

    In fact, I'm getting several "interesting" message boxes. When I enter a value into the first field on each subform, the number disappears when I leave the field. When I enter a number in the 2nd field (in tab order), I get a message box that announces:

    YOU CAN'T ASSIGN A VALUE TO THIS OBJECT.

    * The object may be a control on a read-only form.        (This is not a read-only form. No fields are locked.)

    * The object may be on a form that is open in design view.  (It's the only form open & in form view.)

    * The value may be too large for this field.  (The fields are Number fields formatted as Double in the table & General on the form. All numbers are below 100.)

    If I leave that field, the first digit of the number I entered is in the field and I can go back to finish the entry and leave the field without any further problem.

    At that point, if I go back and enter a number into the first field, I get the "You must enter a value in the 'tRecipMeasurements.RecipFName' field." message box. I can still enter values into all the other fields, but when I try to move to the next subform, I again get the "You must enter a value in the 'tRecipMeasurements.RecipFName' field." message box until I exit from the Parent form, when I am told the information cannot be saved at this time. However, when I reopen the database and check in the table, some of the numbers (but not all) have been saved in the table.

    What shall I check next, please?

    Was this answer helpful?

    0 comments No comments
  2. Anonymous
    2012-05-03T22:46:36+00:00

    Create the master/child link using the main form and each subform without any link to the combo.

    Check that you can enter/edit data.

    Use the unbound combo to filter the main form (e.g. FindFirst or Filter), and that will automatically filter the subforms through the master/child link.

    Was this answer helpful?

    0 comments No comments