Home > Back-end > Consult, Delphi writing ocx DLL with c problem
Consult, Delphi writing ocx DLL with c problem
Time:10-03
Java BS development has been doing, so don't know much about Delphi, consult everybody! Project needs to be done in an interface, because to call DLL, so only use js calls ocx, ocx as an intermediary call interface DLL, the implemented before other interface, so the scheme is feasible, This call DLL is API is likely (C), the way of the header file is as follows: Typedef void (WINAPI * Callback) (char * MSG);//callback function type Extern "C" { Void __stdcall SetClientCallback (Callback lpCallback); Void __stdcall Request (const char * EntPara, char * RetPara, short * iRetValue); } The interface definition: Void Request (char * EntPara [in], char * RetPara [out], Short * iRetValue [in, out]) Current static statement 1: Procedure Dll_Request (var inPara, outPara: PChar; Var retPara: an array of short); Stdcall; External 'miclient. DLL' name 'Request; The Dll_Request (inPara outPara, retPara); There seems to be a abnormal call
The static statement 2: Procedure Dll_Request (var inPara outPara: an array of char; Var retPara: an array of short); Stdcall; External 'miclient. DLL' name 'Request; The Dll_Request (inPara outPara, retPara); Call property does not return
What should consult calls to correct
CodePudding user response:
Short * iRetValue corresponding translation for iRetValue: PShortInt