Results 1 to 5 of 5
  1. #1
    gstylianou is offline Competent Performer
    Windows 7 32bit Access 2007
    Join Date
    Dec 2013
    Posts
    167

    Update fields from subform to main form

    I greet all forum




    I need once again the help of more experienced ....


    On my database I have a form (frmCustomers) that incorporates a subform (subfrmCustomerDetails). In the subformCustomerDetails i have the fields "Age" and "Height". I need when updating those fields the corresponding fields "Cage" and "Cheight" which are located in the main form (frmCustomers) to be updating also.


    Although I have tried various methods i have not managed to achieve the desired solution. So, i have error from vba.


    Any help welcomed and appreciated.


    Sincerely,

  2. #2
    ItsMe's Avatar
    ItsMe is offline Sometimes Helpful
    Windows 7 64bit Access 2010 32bit
    Join Date
    Aug 2013
    Posts
    7,862
    Here is some reference material to get the syntax for referencing subforms
    http://access.mvps.org/access/forms/frm0031.htm

    Having said that, make sure not to duplicate data from one table to another unless said data is a Key value. Storing literal text from multiple columns of a single record is not normalized. Store the Primary Key value from one table in the corresponding Foreign Key field of another table. Then, join on the PK/FK fields in your queries to retrieve relative data of your relations.

  3. #3
    ranman256's Avatar
    ranman256 is offline VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,525
    I see no reason for a child record to update a master record.

  4. #4
    gstylianou is offline Competent Performer
    Windows 7 32bit Access 2007
    Join Date
    Dec 2013
    Posts
    167
    Ramman the field "Age" is a calculated field, that's why i need this update.

    Its me, i will check out on the article and i will let you know. Thanks

  5. #5
    gstylianou is offline Competent Performer
    Windows 7 32bit Access 2007
    Join Date
    Dec 2013
    Posts
    167
    Good morning all,

    i would like to thank you very much for your help. This issue has been solved because of your help.

    Thanks a lot

    Regards

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 3
    Last Post: 03-17-2014, 12:51 PM
  2. Replies: 8
    Last Post: 05-30-2013, 05:06 PM
  3. Update Main Form From Subform
    By burrina in forum Forms
    Replies: 7
    Last Post: 02-06-2013, 03:55 PM
  4. Requery subform after update of main form
    By gemadan96 in forum Forms
    Replies: 3
    Last Post: 10-17-2012, 02:33 PM
  5. Replies: 1
    Last Post: 07-20-2012, 09:48 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums