castor2003
Programmer
I have this project with a .prg which defines an OLEPUBLIC class that I want to send to someone as a .dll from which the functions can be run. This is what a what I did.
In the project's TESTDLL.PRG. Only item in the project.
After BUILDing this project, I wrote the following PRG to call it as an API
When I run that PRG I get the message "Cannot find entry point trnsform in the DLL"
What could I be doing wrong?
In the project's TESTDLL.PRG. Only item in the project.
Code:
DEFINE CLASS holy AS CUSTOM OLEPUBLIC
PROCEDURE trnsform
LPARAMETERS nLen,cText,cRetvalue
****
*OTHER CODE HERE
*****
RETURN cReply
ENDDEFINE
After BUILDing this project, I wrote the following PRG to call it as an API
Code:
DECLARE INTEGER ShellExecute IN shell32.dll ;
INTEGER hndWin, ;
STRING cAction, ;
STRING cFileName, ;
STRING cParams, ;
STRING cDir, ;
INTEGER nShowWin
cFileName = [regsvr32.exe]
cParams =[/s mybuilt.dll]
cDir = []
cAction = [OPEN]
=ShellExecute(0,cAction,cFileName,cParams,cDir,0)
DECLARE STRING trnsform IN "mybuilt.dll" ;
LONG nLen, STRING cText, STRING cRetvalue
nLen = 3
cText = [Hello World]
cRetvalue = [SIZE]
? trnsform(nLen,cText,cRetValue
When I run that PRG I get the message "Cannot find entry point trnsform in the DLL"
What could I be doing wrong?