0
Reply

how to used unmanaged class library on a C# web application

smallcase

smallcase

Jan 30 2005 10:58 PM
1.7k
Hi, guys I am trapped into a big trouble on how to use unmanaged class library code in a C# web application. Now, I am working on a project to develop a web interface for SPlus, a statistical software tool. By intuitive, I plan to apply C# to develop web side, which will invoke some unmanaged code to use functions of SPlus. I have developed a unmanaged C++ class UM_A to use SPlus functions, and also developed a wrapped managed C ++ class M_A for that unmanaged class UM_A, and used managed M_A in the C# application. First, I tried those unmanaged and managed classes in a window-based C# application, they are really working, and then, I move them to web application. They are failed. The failure is related to an exception of "FileNotFoundException", suggesting that File or assembly name M_A, or one of its dependencies was not found. I am very puzzled. Could you guys tell me what is going on? I know that C# web application can use Pinvoke c to reuse window DLL, and Marshaling to visit COM. But can it reuse old class library by way of wrapped managed class, and how to do? I read many articles on how to utilize wrapped managed class for the reuse of unmanaged class library, but all of them are related to windows application. Thanks david