Results 1 to 3 of 3
  1. #1
    jzacharias is offline Advanced Beginner
    Windows Vista Access 2010 (version 14.0)
    Join Date
    Sep 2010
    Posts
    31

    Parameter prompts when subforms load


    I have a main form with 3 subforms. When I first open the database I receive parameter prompts and if I cancel them the subforms don't load correctly. If I close and reopen the main form everything loads fine. The subforms reference a control on the main form and I'm guessing the control isn't available as the subform loads before the main form. Is there a way to delay the loading of the subforms until the control on the main form is available?

  2. #2
    ranman256's Avatar
    ranman256 is offline VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,525
    Either you have a text box bound to a field that
    does not exist in the query
    or
    is spelled wrong.

  3. #3
    Micron is offline Virtually Inert Person
    Windows 7 32bit Access 2007
    Join Date
    Jun 2014
    Location
    Ontario, Canada
    Posts
    12,801
    As you say, subform events occur first, then the main form. From a purist's point of view, it's probably better to prevent this by design, but I'd say it's not always possible. I presume you are aware that setting parameters, filters etc. will often fail on the open event and you are in fact trying to set these in a load event. You can Google "ms access subform form load order" and you will find some approaches. here's one: https://accessexperts.com/blog/2013/...re-main-forms/

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

Similar Threads

  1. Replies: 12
    Last Post: 12-07-2015, 07:10 PM
  2. Replies: 3
    Last Post: 01-03-2013, 04:32 PM
  3. Replies: 1
    Last Post: 11-27-2012, 04:50 PM
  4. Form with multiple subforms, many prompts
    By funkstrong in forum Forms
    Replies: 2
    Last Post: 10-12-2011, 11:40 AM
  5. Custom Query Parameter Prompts-- Problem
    By tylerthompson in forum Forms
    Replies: 11
    Last Post: 07-07-2009, 10:28 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