Home > Net >  C # call DLL in the parameters of the void * c how to pass?
C # call DLL in the parameters of the void * c how to pass?

Time:11-13

C + + header file called

 
The namespace CSDK
{
Extern "C" __declspec (dllexport) int the initialize (char * key, void * sdkDelegate)
}


The void * sdkDelegate are defined as follows:

 
The class ClientDelegate
{
Public:

Virtual void sendMessage (char * messageID, int sendResult)=0.

Virtual void receiveMessage (int msgType, void * msgObject)=0.
}



Excuse me each great god c # the initialize method, how to transfer void * sdkDelegate this parameter ah,,, thank you


 
[DllImport (DLLPATH, EntryPoint="initialize" CharSet=CharSet. Ansi, CallingConvention=CallingConvention. Cdecl)]
Public static extern int the Initialize (string appkey, IntPtr a);




  •  Tags:  
  • C#
  • Related