ActiveX control that is contained in an Access form does not appear when the design-time license is not available

Content provided by Microsoft

This article applies to a Microsoft Access database (.mdb) file or to a Microsoft Access database (.accdb) file.

Novice: Requires knowledge of the user interface on single-user computers.

Symptoms

In an Access database, a form may have a licensed MFC ActiveX control. Additionally, the form may also have another control such as a text box that is bound to a field of a linked table. If you open this form in Form view, the MFC ActiveX control may not appear. This problem occurs when the design-time license option for the MFC ActiveX control is not available on the same computer where the form resides.

Note If you add an MFC ActiveX control to your form, and the MFC ActiveX control is licensed with a design-time license. The availability of the design-time license on the same computer where the form resides is not required unless the form is opened in Design view.

Cause

This problem occurs when Access tries to open the form in Design view to make name changes when Perform name AutoCorrect is enabled for the database that contains the form. Because the design-time license is not available on the computer, Access unregisters the MFC ActiveX control. Therefore, the MFC ActiveX control does not appear.

Workaround

To work around this problem, disable Track name AutoCorrect info for the database or disable Perform name AutoCorrect for the database before you register the MFC ActiveX control on the computer. To do this, follow these steps:

Start Access.

Open the database that contains the form with the MFC ActiveX control.

On the Tools menu, clickOptions.

Note In Access 2007, click the Microsoft Office Button, and then click Current Database.

In the Options dialog box, click theGeneral tab, and then click to clear the Perform name AutoCorrect check box.

Notes

In Access 2007, click to clear the Perform name AutoCorrect check box under Name AutoCorrect Options.

You may also click to clear the Track name AutoCorrect info check box for the database. When you click to clear the Track name AutoCorrect info check box, thePerform name AutoCorrect option is unavailable.

Close the database.

Exit Access.

Move to the command prompt, and then run regsvr32.

When you run this command, this registers the MFC ActiveX control (.ocx file).

Open the form in Form view.

The MFC ActiveX control appears in the form.

More Information

When you enable Track name AutoCorrect info for the database, Access creates a name map for each object in the database. The name map is used to track name changes. If Perform name AutoCorrect option is also made available, Access verifies that the required name change is applied to the object or to its contents each time that the object is opened. If a change has occurred, the name changes are made automatically.

The problem occurs when you move the database that contains the form to another computer, together with the MFC ActiveX control file (.ocx), and then you re-link the table that is referred to by the control (such as text box) in the form. When you re-link the table, this activates Track Name AutoCorrect info for the form. When you open the form in Form view, Access tries to perform the name correction automatically by opening the form in Design view. This fails because the design-time license for the MFC ActiveX control does not exist. Therefore, the MFC ActiveX control does not appear on the form.

This problem does not occur if the form does not contain any references to linked tables.