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

    Update (requery) one form after inserting new record on seperate form

    I have reviewed many threads but none seem to share my specific problem.
    I have one form (split) used to show all records in a dataview. I have added a column from which a spefic record's details can be reviewed in a seperate details form. Alternatively the user may select the 'new' button opening the details form from which a new record can be added. I wish to highlight, the details form is not a subform, it is a seperate form.
    My issue is updating (i.e. requery) the original record browser form to reflect either changes to a record or the creation of a new record done using the details form.

    The original browser form is called "frmQualificationsBrowser"

    The details form is called "frmQualificationsDetails"

    I have tried the following VB code in frmQualificationsDetails without success


    Code:
    Private Sub Form_Close()
        Forms!frmQualificationBrowser.Requery
    End Sub
    I have also tried the following VB code in frmQualificationsBrowser, also without success
    Code:
    Private Sub Form_GotFocus()
        Me.Requery
    End Sub
    Any help will be most appreciated.
    Thanks
    Peter

  2. #2
    rpeare is offline VIP
    Windows XP Access 2003
    Join Date
    Jul 2011
    Posts
    5,442
    you may need to do a refresh depending on how your form is set up. Try putting a me.refresh before your requeries and see what happens. I think based on your description what is happening is that you are entering a record that is related to an existing item in another table but when you requery your results it's not finding the existing record. If that's not the case I'd likely want to see a sample database with an example of what you are attempting to do and what the results you want are.

  3. #3
    PeterPeterson is offline Novice
    Windows 7 64bit Access 2007
    Join Date
    Sep 2012
    Posts
    7
    rpeare,
    Thanks so much -refreshing before requering solved my problem.
    Regards
    Peter

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

Similar Threads

  1. Replies: 1
    Last Post: 01-24-2012, 03:47 PM
  2. Replies: 1
    Last Post: 11-01-2011, 07:33 PM
  3. same form for new and update record
    By lizu in forum Forms
    Replies: 3
    Last Post: 06-20-2011, 08:34 AM
  4. Requery only one record on a form
    By mkallover in forum Forms
    Replies: 3
    Last Post: 01-26-2011, 09:31 AM
  5. Replies: 6
    Last Post: 01-13-2010, 02:41 PM

Tags for this Thread

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