hello
I've got a C DLL that I've built which has got a callback function. Now I
want to call it from C#.
The method of using a delegate for the callback function works absolutely
beautifully.
However, the exported function of the Dll (that I PInvoke from c#) has an
LPVOID parameter for extradata, which it passes to the callback function.
How would I go about coding it if I wanted to pass a reference to a C# class
through this LPVOID? Do I need a HandleRef, and IntPtr, unsafe code?
Please enlighten me!
Thanks