Results 1 to 5 of 5
  1. #1
    2 Star Lounger
    Join Date
    Jun 2005
    Location
    Atlanta, Georgia, USA
    Posts
    208
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Continous form and filtering (2003)

    I have a continuous based of a query and I am trying to allow users to filter by putting unbound text boxes at the top of the form. The detail information in the form has first name, MI and last name. The unbound text boxes are linked to a query and if they want to search for first name that starts with a then the form will show all first names that start with a. I have the query referencing the unbound text box by using Like [forms]![FrmProvSearch]![Fname] & "*" and I have different ones set up for middle initial and last name. In the after update event of the unbound text box I have me.requery. However, when I press enter it doesn't filter. What could be the problem?

    Thanks

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Continous form and filtering (2003)

    Looks OK, so check carefully that the name of the form and of the text box have been spelled exactly correct.

  3. #3
    2 Star Lounger
    Join Date
    Jun 2005
    Location
    Atlanta, Georgia, USA
    Posts
    208
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Continous form and filtering (2003)

    I can get it to filter on first name but if I use Like [Forms]![FrmProviderSearch]![Mid] & "*" in the query to bring up middle initials that start with a certain letter it doesn't work. I have placed the criteria on a different line to make it an or statement such as Like [Forms]![FrmProviderSearch]![Fname] & "*" or Like [Forms]![FrmProviderSearch]![Mid] & "*" . It is not filtering when I use 2 criteria . Can you tell what is not correct?

  4. #4
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Continous form and filtering (2003)

    By putting the conditions on different lines, you will always return all records if at least one of the text boxes is empty. Try placing the criteria on the same line (i.e. using AND instead of OR).

  5. #5
    2 Star Lounger
    Join Date
    Jun 2005
    Location
    Atlanta, Georgia, USA
    Posts
    208
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Continous form and filtering (2003)

    Thanks that works.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •