T
Treadstone
Hi,
Being a newbie to C# and having worked with C all the way, I am stuck
with an interop problem.
I have a DLL exporting certain functions (and written in C).
The signature of 1 such function is as follows:
extern "C"
{
__declspec(dllexport) int EnumerateDevice(DEVICE **DeviceList);
}
struct DEVICE
{
int DeviceNo;
DEVICE *next;
};
I need to call this function from my C# code. How do I go about doing
this? I went through some interop samples but most of them use basic
data types (int and char) as parameters in their examples.
Any code sample in this regard would be useful.
Thanks in advance.
Regards,
Treadstone
Being a newbie to C# and having worked with C all the way, I am stuck
with an interop problem.
I have a DLL exporting certain functions (and written in C).
The signature of 1 such function is as follows:
extern "C"
{
__declspec(dllexport) int EnumerateDevice(DEVICE **DeviceList);
}
struct DEVICE
{
int DeviceNo;
DEVICE *next;
};
I need to call this function from my C# code. How do I go about doing
this? I went through some interop samples but most of them use basic
data types (int and char) as parameters in their examples.
Any code sample in this regard would be useful.
Thanks in advance.
Regards,
Treadstone