Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
OleControl must have container?
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Contrôles ActiveX en VFP
Divers
Thread ID:
00534134
Message ID:
00534214
Vues:
22
>>I am using the oleControl base class to subclass a non-visual ActiveX control. When I try to instantiate the subclassed control in code, I get error 1435 "Object class is invalid for this container". So I tried putting the class in a container. When I try to instantiate the container, I get the same error. If I put the ole class in a form class and instantiate it, it works. So, I have two questions:
>>
>>1) Must the oleControl in fact be instantiated within a container?
>>
>>2) Must that container be a form?
>>
>>I would rather have less overhead than a form if possible.
>>
>>Thanks.
>
>
>ActiveX controls vary on a control by control basis as to the kinds of containers that may contain them. It sounds like the particular control that you are using must be placed directly on a form. (others might be able to be placed in non-form containers, it varies by the control)
>
>-Lou.

I didn't know ActiveX controls could be that picky about the host environment. You're probably right though. All of the docs and examples say to drop the control on a form.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform