Results 1 to 7 of 7
  1. #1
    Erictsang is offline Competent Performer
    Windows 10 Access 2016
    Join Date
    Jul 2017
    Posts
    154

    Requery

    Dear all



    I have made a form that will let user to complete the data /requirement for the search

    after user input the payment mode, then click search


    However, the query need to be manually refresh .. how can i do it that it will automatically refresh as i click the search ?Click image for larger version. 

Name:	Requery.JPG 
Views:	24 
Size:	17.4 KB 
ID:	30099



    See below photo

  2. #2
    Bob Fitz's Avatar
    Bob Fitz is offline Access Developer
    Windows 7 32bit Access 2013
    Join Date
    May 2011
    Location
    Essex UK
    Posts
    3,614
    I would use a form or a report (based on the query) to present the result to the user.
    If this helped, please click the star at the bottom left of this posting and add to my reputation . Many thanks.
    Bob Fitzpatrick

  3. #3
    alansidman's Avatar
    alansidman is offline Indifferent
    Windows 10 Access 2016
    Join Date
    Apr 2010
    Location
    Steamboat Springs
    Posts
    2,538
    In the afterupdate event for the text box

    me.requery

  4. #4
    orange's Avatar
    orange is offline Moderator
    Windows 10 Access 2010 32bit
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,870
    What is the code behind the Search button?

    You might consider (untested)
    -in the before Update event of the Form
    ---ensure there is a valid Date
    ---ensure there is a selection in the combo
    ---if either is false, then give a message and go back to the control involved.

    ---if both are true, then do a me.Requery

    User then click the button

    OR

    Do as Alan says if you are not checking for specific values.

  5. #5
    Erictsang is offline Competent Performer
    Windows 10 Access 2016
    Join Date
    Jul 2017
    Posts
    154
    Orange

    I tried but it prompt- i assign this marco in the unbound box

    Click image for larger version. 

Name:	Requery.JPG 
Views:	15 
Size:	57.9 KB 
ID:	30100

  6. #6
    orange's Avatar
    orange is offline Moderator
    Windows 10 Access 2010 32bit
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,870

  7. #7
    Erictsang is offline Competent Performer
    Windows 10 Access 2016
    Join Date
    Jul 2017
    Posts
    154
    Bob

    Would you be so kind to have a look on my accdb file

    Thanks

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. Requery
    By Erictsang in forum Macros
    Replies: 3
    Last Post: 08-23-2017, 07:03 AM
  3. requery
    By texas1014 in forum Queries
    Replies: 7
    Last Post: 06-18-2015, 02:55 PM
  4. Requery
    By Grizz2 in forum Queries
    Replies: 2
    Last Post: 05-31-2011, 10:23 AM
  5. Requery?
    By CO711 in forum Forms
    Replies: 0
    Last Post: 08-06-2008, 08:03 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