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:
00534614
Vues:
16
>>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.
>
>A way that I have used an OLE control that must be placed on a form is to create a base form object and add your control to it, but not activate the form, just use it to hold your control.
>
>Here is an example:
>
>
>oDummyForm = CREATEOBJECT("FORM")
>
>* must include the OLE class of the object as fourth parameter of AddObject()
>* you can see what it is if you drop the control on a form in the
>* form designer and look at the OLEclass property on the property sheet
>* on the All or Other tab
>oDummyForm.AddObject("oleZipControl","MyZipCtrl","XCEEDZIP.XceedZipCtrl.1")
>oMyControl = oDummyForm.oleZipControl
>
>
>In this example I am creating a reference to my customized XCEEDZIP control. I defined the CLASS "MyZipCtrl" in a PRG and use this method to create an instance of it.
>
>Be sure to release both variables to release the instance of your control.
>
>Hope this helps,
>-Lou.

Oops, make that "as the THIRD parameter" in the example comment.

-Lou.
"All my life I said I wanted to be someone ...
I can see now that I should have been more specific." -Jane Wagner
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform