Unable to obtain namespace for referanced DLL compiled with /CLR. RRS feed

  • Question

  • Maybe I'm just an idiot but I can't get the ANN (www.cs.umd.edu/~mount/ANN) DLL to export it's functions when I compile it with CLR enabled, it adds as a reference but I can't access any of the functions/classes/members.
    As I said, this is probably a noob question of the highest magnitude but I really am getting desperate. I looked into generating a wrapper with SWIG but ended up with a headache instead. Any ideas? I really don't want to have to resort to using P/Invoke or its ilk to get access.
    Tuesday, March 4, 2008 1:35 AM


  • If you want to access the functions in the native DLL, just recompiling it using /CLR switch is not enough, you have to wrap the native functions in a ref class to be recognized by the managed code, or you will have to use Pinvoke. For more details, please post your question at Visual C++ Language.
    Wednesday, March 5, 2008 6:21 AM