Ted,
-Correct typo in declare line.
-Either remove 'protected' or provide another class method that could access protected method (otherwise you'd get 'Unknown name').
-You call OLE MTDLLs via object creation not declare dll
Assuming you've corrected typo, removed protected clause and compiled to a dll name OlePubTest :
dimension array1[2,3], array2[3]
cCheck = "T"
cType = "2002"
A = ""
array1[1,1] = 0
array1[1,2] = " "
array1[1,3] = " "
array1[2,1] = 0
array1[2,2] = " "
array1[2,3] = " "
array2[1] = " "
array2[1] = " "
array2[1] = " "
? Before MTDLL call
disp memo like array1
disp memo like array2
oTest = create('olepubtest.MyProcedures')
COMARRAY(oTest,11)
a = oTest.pgetvarioussubfunctions(cCheck,cType,@array1,@array2)
? a
? After MTDLL call
disp memo like array1
disp memo like array2
Cetin
>I have created a project MyLibrary that contains only one PRG that contains the following procedure
>
>PRG NAME pgetvarioussubfunctions.prg which has the following code:
>
>
>DEFINE CLASS MyProcedures AS CUSTOM OLEPUBLIC
>
> PROTECTED PROCEDURE pgetvarioussubfunctions
> Parameters pParm1, pParm2, pParm3, pParm4
>
> LOCAL cReturn
> DECLARE arrayX[2,3] arrayY[3]
>
> arrayx[1,1] = 1
> arrayx[1,2] = "A"
> arrayx[1,3] = DATE()
> arrayx[2,1] = 1
> arrayx[2,2] = "B"
> arrayx[2,3] = DATE()
>
> arrayy[1] = " "
> arrayy[1] = " "
> arrayy[1] = " "
>
> =acopy(arrayX,pParm3)
> =acopy(arrayY,pParm4)
>
> cReturn = "Any String"
>
> RETURN(cReturn)
>
> ENDPROC
>ENDDEFINE
>
>Now I try to access the DLL generated with the following program and get a message “No entry point for pgetvarioussubfunctions”
>
>declare array1[2,3]
>declare array2[3]
>cCheck = "T"
>cType = "2002"
>A = ""
>array1[1,1] = 0
>array1[1,2] = " "
>array1[1,3] = " "
>array1[2,1] = 0
>array1[2,2] = " "
>array1[2,3] = " "
>array2[1] = " "
>array2[1] = " "
>array2[1] = " "
>
>Declare string pgetvarioussubfunctions IN MyLibrary.DLL string cCheck, string cType, string @array1, string @array2
>
>a = pgetvarioussubfunctions(cCheck,cType,@array1,@array2)
>
>?a
>
>Can someone tell me what am I not doing right.