Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Error when acessing winsock
Message
De
16/12/2003 16:28:32
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Problèmes
Divers
Thread ID:
00859548
Message ID:
00859670
Vues:
18
no, what i did was NewObject("MSCTRL1","OC1") without the 'oForm." and of course fox didn't like that at all.

now, my last version is like your example oForm.NewObject("MSCTRL1","OC1") and it initializes fine, but it times out when trying to connect every time.

any ideas?


>?? So this code send you invalid container message?
>
>oForm = CREATEOBJECT("Form")
>oForm.NewObject("MSCTRL1","OC1")
>oForm.MSCTRL1.Visible=.T.
>oForm.Show(1)
>DEFINE class OC1 as olecontrol
>         OleClass = 'mswinsock.winsock'
>ENDDEFINE
>
>
>Perhaps you are missing subclass the Winsock control into an OleControl Class.
>
>>ja i know, but originaly i did:
>
>
CREATE('mswinsock.winsock')
>
>>then i tryed:
>
>oSock = NewObject("_WinSock", This.ClassLib)
>(this one wouldn't do it because "Invalid container")
>
>>and then i tried:
>>ThisForm.AddObject()
>
>>i don't think there is another one, or am i missing something here?
>
>>i even went and manually unregistered and registered the .ocx with no success.
>
>
>
>>In the KBArticle say you can't use AddObject. Use NewObject instead.
>>
>>"Add the control you want to use into a class that is saved in a Visual Class library or into a class created with the DEFINE CLASS command. Next, add an instance of the class at run-time instead of adding the control. Please see the MORE INFORMATION section for details."
>>
>>Hope this helps.
>>
>>>Thank you for your reply
>>
>>>that did not do the trick. i just test it by creating a class of winsock, then instantiating the class with ThisForm.AddObject().
>>
>>>i still get the same error.
>>>BUG: License Error with ActiveX Control Added at Run-Time
>>>
>>>http://support.microsoft.com/?scid=192693
>>>
>>>
>>>Hope this helps
>>>
>>>>hello everybody
>>>
>>>>i know i have seen this beeing discussed here at Universal Thread before - just can't remember where it was.
>>>
>>>>when trying to send e-mail via winsock i get the following error:
>>>
>>>>OLE error code 0x80040112: Class is not licensed for use.
>>>
>>>>it works fine on my developer machine but on another winXP it does not. if i remember correctly it was an install problem, right?
>>>
>>>>i have my own homemade install routine which registers/proccesses ocx/dlls. i gues it does not do it correctly. what should i be looking for, and what 'testing' routine could i include in my install to ensure correct installment?
>>>
>>>thanks for all your help as always!
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform