Microsoft KB Archive/926700

= Error message in Access 2007 when you try to open a table or a query in design mode in a database that is from an earlier version of Access: &quot;The expression you entered refers to an object that is closed or doesn't exist&quot; =

Article ID: 926700

Article Last Modified on 10/15/2007

-

APPLIES TO


 * Microsoft Office Access 2007

-



SYMPTOMS
You open a database that is from an earlier version of Microsoft Access in Microsoft Office Access 2007. When you try to open a table or a query in design mode, you receive the following error message:

Microsoft Office Access

The expression On Click you entered as the event property setting produced the following error:

The expression you entered refers to an object that is closed or doesn't exist.


 * The expression may not result in the name of a macro, the name of a user-defined function, or [Event Procedure].


 * There may have been an error evaluation the function, event, or macro.



CAUSE
This issue may occur when a table or a query has the same name as a form or a report in the Access 2007 database.



RESOLUTION
To resolve this issue, rename the form or the report so that it differs from the name of the table or the query.

Caution Name AutoCorrect fixes most issues that occur when you rename any forms, reports, tables, or queries. However, Name AutoCorrect does not repair tables, queries, or field name changes in macros or in code. Also, Name AutoCorrect does not track changes to form, report, or control names. You may have to fix some references manually. Therefore, make sure that you make a backup copy of the database before you make any changes.

To rename the form or the report in the database, follow these steps:  Click the Microsoft Office Button, and then click Open. In the Open dialog box, select the database that you want to open, and then click Open. If you receive the following message, click Options, click Enable this content, and then click OK.

Please enable code in this database using the security bar above or open this file from a trusted folder.

 Click the Microsoft Office Button, and then click Access Options. In the Access Options dialog box, click Current Database. Under Name AutoCorrect Options, make sure that the Perform name Autocorrect check box is selected. If it is not selected, click to select the Perform name Autocorrect check box. Then, close and reopen the database for the change to take effect. In the Navigation Pane, right-click the form or the report, and then click Rename.</li> Type a new name for the form or for the report, and then press ENTER.</li> On the Quick Access toolbar, click Save.</li></ol>

For more information about how to rename a form or a report, follow these steps:
 * 1) Click Microsoft Office Access Help, or press F1.
 * 2) Type rename or delete objects in the Search box.
 * 3) To view the topics, click Search.

Additional query words: access2007 access2k7 access12 acc2007 acc2k7 acc12

Keywords: kberrmsg kbtshoot kbdatabase kbprb kbexpertiseinter KB926700

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.