Results 1 to 4 of 4
  1. #1
    3 Star Lounger
    Join Date
    Dec 2006
    Posts
    250
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Linking fields from main Form to Subform (2003)

    Hello,

    I have created a main form with a subform on it. The subform comes from a different table than the main form. The field I want to link in the subform is not in the table use for the subform. I only want the user to see the field and not edit it in the subform. How can I do this? Any help would be great. Thanks.

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Linking fields from main Form to Subform (2003)

    I'm afraid this is not clear to me. Could you explain in more detail?

    Added later: if you want to display the value of a text box of the main form on the subform, you can use a text box with control source
    <code>
    =[Parent]![NameOfTextBox]
    </code>
    where NameOfTextBox must be replaced with the name of the text box on the main form (the word Parent must not be changed - it is a keyword that refers to the "parent" of the subform, i.e. to the main form, whatever its name is).

  3. #3
    Gold Lounger
    Join Date
    Jun 2001
    Location
    Crystal Beach, FL, Florida, USA
    Posts
    3,436
    Thanks
    1
    Thanked 34 Times in 34 Posts

    Re: Linking fields from main Form to Subform (2003)

    Hard to understand your request. The Linking fields must be present in the recordsource of both the form and subform. But don't put the Linking field as a control on the subform. There is no reason to see it.
    Mark Liquorman
    See my website for Tips & Downloads and for my Liquorman Utilities.

  4. #4
    3 Star Lounger
    Join Date
    Dec 2006
    Posts
    250
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Linking fields from main Form to Subform (2003)

    Sorry for the confusion Hans and Mark. I am new to Access. Hans your approach worked. Thanks.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •