Results 1 to 3 of 3
  1. #1
    krcmd is offline Novice
    Windows 7 64bit Access 2007
    Join Date
    Aug 2012
    Posts
    1

    How to update a subform

    I have a subform on a tab that queries a database modified on other tabs of the main form.


    How do I see that this subform requeries when I switch back and forth between tabs? The subform in question now stays unchanged after I modify the data, unless I leave the master record and return. Thank you!

  2. #2
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 7 64bit Access 2010 32bit
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,917
    It sounds like you need to save the "Master Record" for the SubForms to see the changes.

  3. #3
    June7's Avatar
    June7 is offline VIP
    Windows XP Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,771
    Might have to Requery or Refresh the subform.

    The trick is figuring out what event to put the code in. Maybe the Click event of the tab control page.
    Me.subformcontrolname.Requery
    or
    Me.Subformcontrolname.Refresh

    RuralGuy makes a good point. If the data entered is into record of the main form. But why would a subform have the same data as the main form?
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

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

Similar Threads

  1. SubForm Update
    By libraccess in forum Forms
    Replies: 2
    Last Post: 05-02-2012, 07:02 PM
  2. subform update field
    By bigmac in forum Forms
    Replies: 1
    Last Post: 03-10-2012, 02:57 PM
  3. Update field in table after update on a subform
    By jpkeller55 in forum Queries
    Replies: 3
    Last Post: 09-30-2010, 08:02 PM
  4. update field from one subform to another
    By bluezidane in forum Programming
    Replies: 3
    Last Post: 08-20-2010, 07:54 AM
  5. update recordsource of subform
    By AndyKim in forum Forms
    Replies: 1
    Last Post: 06-16-2009, 09:15 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