Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Updating an OLEControl Classe's Active X
Message
From
18/07/2001 23:59:11
 
 
To
18/07/2001 02:43:03
General information
Forum:
Visual FoxPro
Category:
ActiveX controls in VFP
Miscellaneous
Thread ID:
00531872
Message ID:
00532371
Views:
16
>I've got an OLE Control class which uses the true DB Grid OCX based on the version 6. I just got the version 7.0 and tried to upgrade.
>
>I couldn't figure out how to do it easily so I made a new control and copied the PEMS to it then deleted and renamed it. Worked fine. But when I go into
>all the instances of the class on forms it still lists the old control version.
>(They are two different OCX files.)
>
>How do I make all the forms use the new version without adding all these ActiveX's again to each form?
>
>Shouldn't this be easier since I subclassed it?
>
>Is there no easy way to do this or do I have to copy all the settings
>and extra code in the object to a new object and re drop it on all forms?

This is not particularly pretty.

In essence, when you upgrade many .ocx files, it is necessary to replace all instances of the control, base or subclassed, in the application. The .vcx and .scx files that one installs them into, via the OLE Control class, records information about the original .ocx. If this information does not match what is found in the .ocx, such as when one upgrades the .ocx, the new .ocx is not recognized.

You did exactly what must be done in order to install a new .ocx. I even tried creating the OLE Control class in a .prg, but in a best-case scenario, the program only ran successfully on the development machine, where the license file resided. This has been my experience with several .ocx files, and has made me wary of upgrading ActiveX controls unless the is a serious bug that the new version addresses, or I need the additional functionality that the new control offers.
David M. Stowell
Ravenslake Consulting
Chicago, Illinois

e-mail: davidstowell@ravenslakeconsulting.com
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform