Error Checking in Excel
Thanks Thanks:  0
Likes Likes:  0
Results 1 to 6 of 6

Thread: Excel Query Criteria

  1. #1
    Board Regular
    Join Date
    Feb 2002
    Location
    Dallas, TX
    Posts
    316
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Hello all,

    I'm using the MS query in Excel and instead of using the criteria filters in MS Query I'd rather use Excel combo boxes, drop downs etc. Is there a way to populate the criteria filters in MS query from a control box?

  2. #2
    MrExcel MVP lenze's Avatar
    Join Date
    Feb 2002
    Location
    Helena, MT
    Posts
    13,690
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    If you use design mode to create or edit your query, you can include a parameter to be prompted for on refresh. You can then go to parameter options and link the parameter to a cell. You will have the option to select automaticcaly refresh when this cell changes. Use a combo box or data validation to populate this cell

  3. #3
    Board Regular
    Join Date
    Feb 2002
    Location
    Dallas, TX
    Posts
    316
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    The only thing I see in parameter options is to change the name of the parameter. Am I looking in the right place?

  4. #4
    MrExcel MVP
    Join Date
    Feb 2002
    Location
    Austin, Texas USA
    Posts
    11,654
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    On 2002-04-26 07:56, spg2112 wrote:
    The only thing I see in parameter options is to change the name of the parameter. Am I looking in the right place?
    Here's an example of a parameter query that prompts for a value...

    SELECT Table1.Customer
    FROM Book2.Table1 Table1
    WHERE (Table1.Call_Date=?)

    You can then configure the external data range to accept a parameter value from a worksheet cell. See the Excel Help Index topics for...

    1. Create a query that prompts for criteria
    2. Use data from a cell on a worksheet as a parameter value

  5. #5
    MrExcel MVP lenze's Avatar
    Join Date
    Feb 2002
    Location
    Helena, MT
    Posts
    13,690
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    After you return to Excel from MS query. right click on the date and choose parameters. A dialog box will open with the parameter options

  6. #6
    Board Regular
    Join Date
    Feb 2002
    Location
    Dallas, TX
    Posts
    316
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    That will work! Thanks guys! This board rocks.

    Steve

Some videos you may like

User Tag List

Like this thread? Share it with others

Like this thread? Share it with others

Posting Permissions

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