When instanciating a COM object, you have to specify the name of the file and the name of the class, ie CreateObject("PTAX.MyClassName") (assuming that you have a class named MyClassName)
HTH
>I created an Olepublic class from a prg by using
>DEFINE CLASS ptax as Custom olepublic
>
>I addded the .prg to a project and built a dll by name ptax.dll
>However if I try to create an object based on this class with the following command,
>
>x=createobject("PTAX")
>
>I get an error "CLASS DEFINITION PTAX NOT FOUND"
>
>What am I doing wrong?. I find that the files ptax.dll, ptax.tlb and ptax.vbr are created. I am using VFP 5.0
Précédent
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement