Results 1 to 2 of 2
  1. #1
    tylerpickering is offline Novice
    Windows 7 32bit Access 2007
    Join Date
    Mar 2014
    Posts
    22

    Forms and Filtering Query

    I have a form on my database (Customer) that is a drop-down list that allows the user to select one customer code.

    I have a query that I want to filter my data table based on what the user selects in the customer form (or if blank, returns all customer records).



    Here is my current formula in my query:
    Code:
    Like IIf([Forms]![IMDB]![Customer]="","*",[Forms]![IMDB]![Customer])
    If a certain customer code is selected on the form, it does return results for that customer. However, my issue is when the form is left blank--it returns nothing but I want it to return all results. Am I using the wildcard incorrectly? I also tried IIf(isblank([Forms]![IMDB]![Customer]).... but that didn't work either

    Thanks in advance!

  2. #2
    orange's Avatar
    orange is online now Moderator
    Windows XP Access 2003
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,722
    See this free video tutorial - concepts may be helpful.

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

Similar Threads

  1. Filtering in Forms
    By djclntn in forum Forms
    Replies: 7
    Last Post: 03-21-2013, 05:30 PM
  2. Filtering Forms
    By Lupson2011 in forum Forms
    Replies: 1
    Last Post: 02-07-2012, 04:48 PM
  3. Filtering forms by date
    By rwest in forum Forms
    Replies: 1
    Last Post: 01-03-2012, 11:23 AM
  4. Filtering Forms
    By Iggsy in forum Forms
    Replies: 6
    Last Post: 11-23-2011, 01:01 AM
  5. Combo Box Filtering between Forms
    By andrew_ww in forum Access
    Replies: 3
    Last Post: 12-30-2009, 11:06 PM

Tags for this Thread

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