Results 1 to 7 of 7
  1. #1
    Amyfb is offline Advanced Beginner
    Windows 10 Office 365
    Join Date
    Mar 2021
    Posts
    64

    Parameter query pops up on every query or form associated with the pquery tables.

    I made a parameter query for use on a form, to pull up a short list of records and select one for editing.

    But now, the parameter dialog box appears when I run any query or create any form that is associated with the underlying tables used to make the parameter query.

    That's not what I want.

    How can I prevent the popup when it isn't wanted?

    edit to report SOLVED - I dug around again in all the queries and found that the expression had been added to another query that i was using to make other forms. (I need better notes or something.)



    thanks
    Amy
    Attached Files Attached Files
    Last edited by Amyfb; 08-17-2021 at 08:52 AM.

  2. #2
    kd2017 is offline Well, I tried at least.
    Windows 10 Access 2016
    Join Date
    Jul 2017
    Posts
    1,142
    Any query or form that is derived from your parameter query will ask for those parameters. I'm not sure what you mean by underlying tables being a problem, from what I can tell all is behaving as expected.

    To answer your question directly the only way I know to prevent the popup would be to set the parameter's value in vba, but I'm not sure you need to go that route. There's a 100+ ways your user could select a record for editing, the most obvious way would be to create a search form and remove the parameter from the query.

    When you open your form you would filter it to a specific record, something like this:
    Code:
    DoCmd.OpenForm "Copy of qryDocumentVersions", , , "DOCUMENT_NUMBER = '" & some_criteria & "'"

  3. #3
    kd2017 is offline Well, I tried at least.
    Windows 10 Access 2016
    Join Date
    Jul 2017
    Posts
    1,142
    See attached for a quick example. I created a new form called 'Document List', find a doc you want to edit and click the doc number and it opens your form to edit the record. I also deleted the parameter in the query.
    Attached Files Attached Files

  4. #4
    ssanfu is offline Master of Nothing
    Windows 10 Access 2010 32bit
    Join Date
    Sep 2010
    Location
    Anchorage, Alaska, USA
    Posts
    9,664
    In table "tblVersions", you have a look up field (bad idea) "approved_by".
    The Row Source is a query "qryAllEmployees" that doesn't appear to be in the dB..??

  5. #5
    Amyfb is offline Advanced Beginner
    Windows 10 Office 365
    Join Date
    Mar 2021
    Posts
    64
    [QUOTE=kd2017;481403]Any query or form that is derived from your parameter query will ask for those parameters. I'm not sure what you mean by underlying tables being a problem, from what I can tell all is behaving as expected.]

    The issue is: when I try to make any other form based on a different query or table, that parameter query insisted it was part of the plan. I was trying every way I could to create a form without touching that paramquery but it kept popping up.

    I've clearly skimmed over some key details on planning and know just enough to get in a mess of trouble. Going back to my Access Bible, again and again.

    thanks for the input.

  6. #6
    Amyfb is offline Advanced Beginner
    Windows 10 Office 365
    Join Date
    Mar 2021
    Posts
    64
    Quote Originally Posted by ssanfu View Post
    In table "tblVersions", you have a look up field (bad idea) "approved_by".
    The Row Source is a query "qryAllEmployees" that doesn't appear to be in the dB..??
    Dang! I know better than to do that "bad idea" and don't know what possessed me to put that in there and then promptly forget I did it.
    thanks for catching it, and i'll go clean that up right now.

    thanks

  7. #7
    Amyfb is offline Advanced Beginner
    Windows 10 Office 365
    Join Date
    Mar 2021
    Posts
    64
    Quote Originally Posted by kd2017 View Post
    See attached for a quick example. I created a new form called 'Document List', find a doc you want to edit and click the doc number and it opens your form to edit the record. I also deleted the parameter in the query.
    Thanks for taking the time to create that form and show me something new! I hadn't used linked tables before so that was interesting to see. It only seems to serve for editing existing records. I tried adding a new document, but the link went to a blank record. I'm going to go study up on linked forms to see what i can learn.

    thanks again.

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

Similar Threads

  1. Replies: 2
    Last Post: 01-26-2017, 08:19 AM
  2. Replies: 1
    Last Post: 03-13-2015, 06:24 AM
  3. query with parameter from Form
    By fluppe in forum Access
    Replies: 5
    Last Post: 06-27-2014, 10:02 AM
  4. Need Parameter Query to Open Form
    By HLTAYLOR in forum Misc
    Replies: 3
    Last Post: 06-20-2013, 09:41 AM
  5. two unrelated tables and parameter query
    By Seito in forum Queries
    Replies: 2
    Last Post: 09-12-2011, 03:01 PM

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