Managed c++ Newbie Question on linking Unmanged C++ to c#
-
I'm somewhat new to managed c++, so I would like a little clarification. We have a large codebase of unmanaged c++ that runs as a plugin in another application (VS2002 rocks/NOT). The plugin world has it own coding rules and libraries that we have to use. We are in the process of writing about 300K lines of code and are looking at c# just for the productivity enhancements. Also, they do not all have to run in the plugin. My question is, is it possible with managed C++ to create a COM object that will link some these C# DLL's with are existing plugin code? This would be a huge help if it is not hard. Thanks in advance. Tom
-
I'm somewhat new to managed c++, so I would like a little clarification. We have a large codebase of unmanaged c++ that runs as a plugin in another application (VS2002 rocks/NOT). The plugin world has it own coding rules and libraries that we have to use. We are in the process of writing about 300K lines of code and are looking at c# just for the productivity enhancements. Also, they do not all have to run in the plugin. My question is, is it possible with managed C++ to create a COM object that will link some these C# DLL's with are existing plugin code? This would be a huge help if it is not hard. Thanks in advance. Tom
You don't need C++/CLI to write a COM object, but if you use C++/CLI, you don't need to use COM, you can use .NET to get finer grained access to the C# objects you've written.
Christian Graus - Microsoft MVP - C++ "I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
-
You don't need C++/CLI to write a COM object, but if you use C++/CLI, you don't need to use COM, you can use .NET to get finer grained access to the C# objects you've written.
Christian Graus - Microsoft MVP - C++ "I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
-
Just to clarify, I can use c++/CLI to link my existing base of unmanaged code developed with VS2002?
You'd want to modify your existing app to also use C++/CLI, then, yes. That doesn't mean changing all your code, you just add C++/CLI support.
Christian Graus - Microsoft MVP - C++ "I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )