Results 1 to 3 of 3
  1. #1
    fmoses is offline Novice
    Windows XP Access 2003
    Join Date
    Aug 2009
    Posts
    2

    Form Data Not being passed onto query

    This is probably pretty basic, but i can't seem to figure out where i am going wrong with this.

    I have created a form which an individual can use to enter search information and on enter it will run the query passing on the information. I first created one with comboboxes and worked great. I am now trying to create one using text fields, but for some reason it's not either passing on the data, or something is not working right, and can't figure out why. Please see the attached picture.

    The expression I am using in criteria of query is
    Like [Forms]![srchportalpi]![Last_Name?] & "*"
    I also tried adding a Null statement thinking that if there were any blank data it was causing a problem
    Like [Forms]![srchportalpi]![Last_Name?] is Null
    But that didn't work either.



    If i run the query by itself without the form, and entering the data using the prompts it seems to work fine, but when i enter the data on the form, and then run the query it returns all files in the database. I'm not sure if the issue is with the form (which i think it might be due to query working fine without the form) or the query setup. Any suggestions? Let me know if you need any more info and i'll post it. thanks in advance.

  2. #2
    dcrake's Avatar
    dcrake is offline Competent Performer
    Windows XP Access 2003
    Join Date
    Aug 2009
    Posts
    435
    Take a look at the sample database I posted regarding passing public variables between forms/queries and reports. This might help your with your problem.

    David

  3. #3
    fmoses is offline Novice
    Windows XP Access 2003
    Join Date
    Aug 2009
    Posts
    2
    Quote Originally Posted by dcrake View Post
    Take a look at the sample database I posted regarding passing public variables between forms/queries and reports. This might help your with your problem.

    David
    Thanks for the reply, although your solution is interesting, I think it is more than what is needed for me at this time. The problem just seems to be when i'm using unbound text boxes to capture the data, as when i use combo boxes and type it in using that it works fine. Unfortunately I was hoping to just use text boxes if possible.

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

Similar Threads

  1. Replies: 2
    Last Post: 11-25-2013, 10:56 AM
  2. Use form data in a query
    By Zholt in forum Forms
    Replies: 2
    Last Post: 05-13-2009, 07:59 PM
  3. Replies: 9
    Last Post: 03-24-2009, 09:19 PM
  4. Form does not accept data
    By bongo in forum Forms
    Replies: 3
    Last Post: 03-14-2009, 01:52 AM
  5. Replies: 0
    Last Post: 11-12-2008, 05:18 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