Article ID: 117540
Article Last Modified on 1/19/2007
APPLIES TO
- Microsoft Access 1.0 Standard Edition
- Microsoft Access 1.1 Standard Edition
- Microsoft Access 2.0 Standard Edition
- Microsoft Access 95 Standard Edition
- Microsoft Access 97 Standard Edition
This article was previously published under Q117540
Moderate: Requires basic macro, coding, and interoperability skills.
SYMPTOMS
When you select a form or report wizard:
- In Microsoft Access 7.0 and 97, the wizard move buttons are not available (dimmed), and no fields appear in the field list when you select the form or report wizard.
- In Microsoft Access version 2.0, you receive the error message "Error reading table or query '<name>'" when you select a form or report wizard.
- In Microsoft Access version 1.x, you receive the error message "0 parameters supplied, <number> expected" when you select a form or report wizard.
CAUSE
The query that is selected for the Microsoft Access wizard is a parameterized crosstab query. The wizards require fixed column headings so that you can select the fields to be displayed on the form or report.
RESOLUTION
There are three workarounds for this behavior:
- Define column headings for the crosstab query. In Microsoft Access 2.0 or later, use the ColumnHeadings property. In Microsoft Access version 1.x, choose Query Properties from the View menu in the query's Design view to define fixed column headings.
- Instead of using parameters, enter value ranges in the crosstab query. For example, in the criteria row of the parameterized field, replace between [start date] and [end date] with between #5/15/91# and #5/25/91#.
- In Microsoft Access 2.0 or later, export the results of the query to a Microsoft Excel spreadsheet file, and then import that file into Microsoft Access.
MORE INFORMATION
Steps to Reproduce Behavior
Open the sample database Northwind.mdb (or NWIND.MDB in versions 1.x and 2.0). Create a new query based on the Orders table. Then, on the Query menu, click Crosstab. Create the following query:
Query: Test Wizard -------------------- Type: crosstab query Field: EmployeeID NOTE: In versions 1.x and 2.0, there is a space in Employee ID. Table: Orders Total: Group By Crosstab: Row Heading Field: OrderDate NOTE: In versions 1.x and 2.0, there is a space in Order Date. Table: Orders Total: Group By Crosstab: Column Heading Criteria: Between [start date] and [end date] Field: Freight Table: Orders Total: Sum Crosstab: Value
- On the Query menu, click Parameters. Define Start Date and End Date as Date/Time data types.
- Save the query and then run it. Type 5/10/91 as the start date and 5/15/91 as the end date. Close the query.
- In the Database window, click the Form button, and then click New. In the Select A Table/Query box, select the Test Wizard query. Click the Form Wizards button. Select any of the Form Wizards, and then click OK.
REFERENCES
For more information about column headings, search the Help Index for "ColumnHeadings property," or ask the Microsoft Access 97 Office Assistant.
Keywords: kberrmsg kbprb KB117540