Results 1 to 4 of 4
  1. #1
    tonygg is offline Competent Performer
    Windows 7 64bit Access 2010 64bit
    Join Date
    Mar 2015
    Posts
    115

    Dynamic Filtering on Forms

    Hi. I think I am missing something obvious. Hopefully someone can put me straight.



    Bit of background first:

    I have created a nested set of queries to sum up orders placed by products and then by product ranges. Basically I get all orders with first query and creates some calculated fields. I then summarise the results by product in another query based on the results of the first (again with some calculated fields). I do another grouping query to summarise by product line (groups of products). This all works fine and I can create a form using the third set of results (orders summarised by product line).

    ISSUE: Now comes the problem. I am trying to filter the results in the continuous form. My issue is Access does not allow me create events (subs) to run the filters. If I add a command button and in add code for event "command button clicked" and then try to save the form I get the error:

    ~

    If I take the action to set Has Module to "NO" it removes my code.

    Any ideas what I am doing wrong?

    many thanks

    Tony
    Attached Thumbnails Attached Thumbnails Form Error Msg.jpg  

  2. #2
    ItsMe's Avatar
    ItsMe is offline Sometimes Helpful
    Windows 8 Access 2013
    Join Date
    Aug 2013
    Posts
    7,862
    I have never seen that error before. However, I would try selecting all of the controls and then right click one of the controls. I would select Layout > Remove Layout. It seems your command button is violating some sort of Layout thing.

  3. #3
    tonygg is offline Competent Performer
    Windows 7 64bit Access 2010 64bit
    Join Date
    Mar 2015
    Posts
    115
    It was layout as when I removed all it started working. Thank you

  4. #4
    ItsMe's Avatar
    ItsMe is offline Sometimes Helpful
    Windows 8 Access 2013
    Join Date
    Aug 2013
    Posts
    7,862
    OK, great. Thanks for posting the solution here.

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

Similar Threads

  1. Replies: 3
    Last Post: 09-22-2013, 11:29 AM
  2. dynamic forms
    By ultraplus in forum Access
    Replies: 1
    Last Post: 01-03-2013, 07:43 AM
  3. Dynamic (VBA-Created) Forms in accde?
    By phi11yguy19 in forum Programming
    Replies: 0
    Last Post: 07-02-2011, 09:56 PM
  4. Replies: 3
    Last Post: 03-28-2011, 11:49 AM
  5. Multiple dynamic forms.
    By ser01 in forum Forms
    Replies: 1
    Last Post: 02-22-2010, 11:44 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