Hello I have the following code written in c++ 6.0.I need to write it in C# 2.0 , but i don't knowhow to define those callbacks in C#.Is it possible to use that API in C#?Can any one help me?
Thank YouCaju Ginja
TEST.h
typedef DWORD (CALLBACK* PACCOMSVRCALLBACK_CONNECT)(LPVOID, AC_TERMINAL_CONNECTINFO*, LPDWORD); typedef DWORD (CALLBACK* PACCOMSVRCALLBACK_DISCONNECT)(LPVOID, DWORD);
typedef struct { PACCOMSVRCALLBACK_CONNECT pCallbackConnect; PACCOMSVRCALLBACK_DISCONNECT pCallbackDisconnect;} AC_CALLBACK_FUNCTION_1;
void WINAPI ACCOM_SetCallbackFunctions(LPVOID pParam, DWORD nCallbackType, LPVOID pCallbacks);
///////////////////////////////////////////////////////////////
TEST.CPP
AC_CALLBACK_FUNCTION_1 callbacks;
memset(&callbacks, 0, sizeof(AC_CALLBACK_FUNCTION_1));
callbacks.pCallbackConnect = NULL; callbacks.pCallbackDisconnect = Callback_Disconnected;
ACCOM_SetCallbackFunctions( this, 1, &callbacks);////////////////////////////////////////////////////////////////////