views:

19

answers:

0

Hello,

I have one class library that have all functions declared as public under public class. Still When I am going to call one of those it gives linker errors. Do I need to export these methods explicitly from class library as we export from native dll. When I export with __declspec(dllexport) it says that function cannot be exported with __declspec(dllexport) under /clr.

error LNK2019: unresolved external symbol "public: static class TestNamespace::ClassTest * __cdecl TestNamespace::ClassTest::getInstance(void)" (?getInstance@ClassTest@TestNamespace@@$$FSAPAV12@XZ) referenced in function "int __clrcall main(cli::array^)" (?main@@$$HYMHP$01AP$AAVString@System@@@Z) D:\DTFSourceCode\DTF_BackEnd\COMExtractor\COMExtractorDemop\COMExtractorDemop.obj COMExtractorDemop

Regards Usman