I have a dll that consists of unmanaged C++ routines. I can call a function
in the dll from a C++ executable, but not from a C# executable. I am calling
an independent function, not a class. C# gives me a runtime exception saying
the entry point to the dll cannot be found.
I declare the function in C# with the following lines:
[DllImport("simpleDLL.dll", CallingConvention=CallingConvention.Cdecl)]
public static extern int fnsimpleDLL(int i);
I then call the function with the line:
fnsimpleDLL(1);
Any ideas?