Results 1 to 4 of 4
  1. #1
    UT227 is offline Expert
    Windows 7 32bit Access 2013 32bit
    Join Date
    Feb 2016
    Posts
    581

    Form requery

    I have a button that one of the things I need it to do is to requery. The last part of my code is simply to requery the form. When I do that, it goes back to the first record in the table. Example, I am on record #3 and use the button. It will go back to record #1. In the properties, I have it set to current record. I tried it on current page also, but it did the same thing. Not sure what I'm doing wrong.

  2. #2
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 10 Access 2013 32bit
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922

  3. #3
    UT227 is offline Expert
    Windows 7 32bit Access 2013 32bit
    Join Date
    Feb 2016
    Posts
    581
    That worked great. It flashes to the first record and then goes back to the current records. Thanks.

  4. #4
    isladogs's Avatar
    isladogs is offline MVP / VIP
    Windows 10 Access 2010 32bit
    Join Date
    Jan 2014
    Location
    Somerset, UK
    Posts
    5,954
    To prevent the screen flashing you could temporarily switch off screen updating.
    Try adding Appliation.Echo False before the requery line and Application.Echo True after the End With line.

    Alternatively, depending on how data I being updated, you might be able to use Me.Recalc to update displayed values without returning to the first record
    Colin, Access MVP, Website, email
    The more I learn, the more I know I don't know. When I don't know, I keep quiet!
    If I don't know that I don't know, I don't know whether to answer

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

Similar Threads

  1. AfterUpdate requery does not requery list box
    By ittechguy in forum Programming
    Replies: 5
    Last Post: 09-05-2017, 08:51 AM
  2. Replies: 11
    Last Post: 04-09-2016, 08:54 PM
  3. Replies: 7
    Last Post: 07-01-2015, 10:29 AM
  4. Replies: 3
    Last Post: 08-26-2014, 12:52 PM
  5. Replies: 1
    Last Post: 05-26-2014, 10:31 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