ActiveX control that is contained in an Access form does not appear when the design-time license is not available (824165)
The information in this article applies to:
- Microsoft Office Access 2003
- Microsoft Access 2002
This
article applies only to a Microsoft Access database (.mdb).
Novice: Requires knowledge of the user interface on single-user
computers.
SYMPTOMSIn
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.
CAUSEThis 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.WORKAROUNDTo 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, click
Options.
- In the Options dialog box, click the
General tab, and then click to clear the Perform name
AutoCorrect check box.
Note 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, the
Perform name AutoCorrect option is unavailable. - Close the database.
- Quit 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 INFORMATIONWhen
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.
Modification Type: | Minor | Last Reviewed: | 5/28/2004 |
---|
Keywords: | kbProgramming kbForms kbdisplay kbLicensing kbprb KB824165 kbAudDeveloper |
---|
|