Kbase P110128: Error "Unable to create control" after upgrading to a later version of Crystal Reports
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  10/24/2005 |
|
Status: Unverified
FACT(s) (Environment):
Crystal Reports
Windows
SYMPTOM(s):
Using Crystal Reports ActiveX Viewer control
Error message occurs when opening code that was created against the previous version of Crystal Reports installed on the machine
CtrlFrame.<Name of Control>
Unable to create control.
Specified ActiveX control is not registered or the .ocx file was moved from where it was registered.
CtrlFrame.CrystalActiveXReportViewer
Unable to create control.
Specified ActiveX control is not registered or the .ocx file was moved from where it was registered.
CHANGE:
Upgraded to a later version of Crystal Reports, for example from Crystal Reports 10 to Crystal Reports 11 (XI)
CHANGE:
Previous version of Crystal Reports has been removed
CAUSE:
This is expected behaviour. Each version of Crystal Reports has its own version of the ActiveX Viewer control. When any ActiveX control is added to a Progress window, Progress stores the Class ID of the control in the .WRX file. Whenever a piece of code that utilizes an ActiveX control is loaded, Progress checks for the stored Class ID in the Registry and generates an error if it cannot find it. In this case, the code is looking for the Crystal Reports ActiveX Viewer control from the previous version of Crystal Reports.
FIX:
Regenerate the .WRX files so that they reference the correct version of the Crystal Reports ActiveX Viewer control.
1) Open the code
2) Click OK to the "Unable to create control" error message which will automatically remove the previous version of the control
3) Click on AppBuilder's OCX list and select the Viewer control from the newer version of Crystal Reports
4) Add the control to the AppBuilder window in place of the old version
5) Ensure that the control has the same Name property as the previous version or errors can result when the code is run
6) Configure the control and save the code
This will update the .WRX file with the correct information