Customize a parameter query

Microsoft Office Excel 2003

  1. In Microsoft Excel, click a cell anywhere in the external data range created with a parameter query.
  2. On the External Data toolbar, click Query Parameters Button image.
  3. In the list on the left side of the Parameters dialog box, click the parameter that you want to change.
  4. In the Prompt for value using the following string box, type the text that you want to use for the prompt, and then click OK. The custom prompt can contain up to 100 characters.
  5. To use the new custom prompt and refresh the data, click Refresh Data Button image on the External Data toolbar.

Note  This procedure changes the custom prompt only for the current session of the workbook. If you want to permanently save your changes to the custom prompt, save the workbook or change the prompt for the query in Microsoft Query. For more information about changing a query, see Microsoft Query Help.

ShowUse data from a cell as a parameter value

  1. On your worksheet, type the values you want to use as criteria in the query.
  2. Click a cell anywhere in the external data range created with a parameter query.
  3. On the External Data toolbar, click Query Parameters Button image.
  4. In the list on the left side of the Parameters dialog box, click the parameter you want to change.
  5. Click Get the value from the following cell.
  6. On the worksheet, click the cell that contains the value you want to use.

    If you want to refresh the data whenever you change the value in the cell, select the Refresh automatically when cell value changes check box.

  7. Click OK.
  8. To refresh the data, click Refresh Data Button image on the External Data toolbar.

ShowUse a constant parameter value for a query

  1. In Excel, click a cell in the external data range created with a parameter query.
  2. On the External Data toolbar, click Query Parameters Button image.
  3. In the list on the left side of the Parameters dialog box, click the parameter you want to change.
  4. Click Use the following value.
  5. Type the value you want to use for the parameter, and then click OK.
  6. To refresh the data, click Refresh Data Button image on the External Data toolbar.