N
noe
Hello,
I am writing a class in C# that uses
[DllImport("DllWin32Ndisuio.dll")]to call functions from a C/C++ dll.
-------------------------------------
//Code in C# in Platform .NET
[DllImport("DllWin32Ndisuio.dll", CharSet=CharSet.Auto)]
public static extern bool ConectarNdisuio ( ) ;
[DllImport("DllWin32Ndisuio.dll", CharSet=CharSet.Auto)]
public static extern IntPtr ConectarNdisuioDevuelveHandle ( ) ;
--------------------------------------
//Code in DllWin32Ndisuio.h in Platform Win32
#define DllExport extern "C" __declspec(dllexport)
DllExport bool ConectarNdisuio( );
DllExport HANDLE ConectarNdisuioDevuelveHandle( );
---------------------------------------
If I call the function ConectarNdisuio the operation is executed
correctly, but if I call the function ConectarNdisuioDevuelveHandle
then I get an error and the code isn´t executed correctly.
The code inside the function ConectarNdisuio is the same that the code
inside the function ConectarNdisuioDevuelveHandle, but the functions
return different values.
I don´t know what happens.
Please, help me.
I am writing a class in C# that uses
[DllImport("DllWin32Ndisuio.dll")]to call functions from a C/C++ dll.
-------------------------------------
//Code in C# in Platform .NET
[DllImport("DllWin32Ndisuio.dll", CharSet=CharSet.Auto)]
public static extern bool ConectarNdisuio ( ) ;
[DllImport("DllWin32Ndisuio.dll", CharSet=CharSet.Auto)]
public static extern IntPtr ConectarNdisuioDevuelveHandle ( ) ;
--------------------------------------
//Code in DllWin32Ndisuio.h in Platform Win32
#define DllExport extern "C" __declspec(dllexport)
DllExport bool ConectarNdisuio( );
DllExport HANDLE ConectarNdisuioDevuelveHandle( );
---------------------------------------
If I call the function ConectarNdisuio the operation is executed
correctly, but if I call the function ConectarNdisuioDevuelveHandle
then I get an error and the code isn´t executed correctly.
The code inside the function ConectarNdisuio is the same that the code
inside the function ConectarNdisuioDevuelveHandle, but the functions
return different values.
I don´t know what happens.
Please, help me.