Results 1 to 2 of 2
  1. #1
    Join Date
    May 2005
    Provided Answers: 1

    Unanswered: Run a report based on multiple criteria held in a textbox


    Current set up Access 2007

    I need help please

    At present my end users run reports based on group numbers which they enter into a textbox held within a form, but they can only run a query based on one criteria eg Grp No 10, which is passed through to an internal query.

    What I would like to be able to do, is be able to enter multiple grp no's, seperated by commas e.g.

    10, 11, 12 and so on, which would then be passed to the query

    so the query changes from

    SELECT * FROM RegionalSiteDetailsIncContacts
    WHERE (((RegionalSiteDetailsIncContacts.Statsort) = "10"));

    SELECT * FROM RegionalSiteDetailsIncContacts
    WHERE (((RegionalSiteDetailsIncContacts.StatSort) In ('000010','000011','000012')));
    Basically is this possible, and how would I go about it


  2. #2
    Join Date
    Dec 2012
    Logan, Utah
    I am completely ignorant of all things Access, but could you not just build your string of codes entered into the text box and put the results in a variable and pass that to the query?

    WhereStr = '000010', '000020','000030'

Posting Permissions

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