Results 1 to 4 of 4
  1. #1
    gmaster is offline Advanced Beginner
    Windows 8 Access 2010 32bit
    Join Date
    May 2014
    Posts
    32

    Query with data from form

    Hi, i have a form with a combobox and a text field, and i want to make a query that search those two values (the one selected by the user in the combobox and the one written in the text field) in a specific table...How can i do it??


    Thanks!

    Edit: there's another issue...those two values should be searched in multiple fields, i.e. the combobox should be searched in column1, column2, column3 and the textbox in column4, colum5, column6

  2. #2
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,530
    Generally speaking you put a reference to the form control in the criteria portion of the query builder. The desire to search multiple fields could indicate a normalization problem. To do it you'd put the form reference under each field. Putting them on the same line results in an AND comparison, on different lines results in an OR comparison.
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

  3. #3
    gmaster is offline Advanced Beginner
    Windows 8 Access 2010 32bit
    Join Date
    May 2014
    Posts
    32
    Yes, thanks!!!!!

  4. #4
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,530
    Happy to help!
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

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

Similar Threads

  1. Replies: 10
    Last Post: 02-12-2014, 08:26 PM
  2. Placing query data on the form
    By snowboarder234 in forum Forms
    Replies: 7
    Last Post: 11-07-2012, 11:30 AM
  3. Replies: 9
    Last Post: 09-20-2011, 07:47 PM
  4. Use of form to gather data for a query
    By tarhim47 in forum Forms
    Replies: 10
    Last Post: 11-05-2010, 10:46 AM
  5. Use form data in a query
    By Zholt in forum Forms
    Replies: 2
    Last Post: 05-13-2009, 07:59 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