Reputation: 20644
I am having a C++ project. i would like to port it to a C#.NET project. I have done some research and I think the most popular way is to use pinvoke.
I dont know whether there are also other methods existed?
Thanks in advance.
Upvotes: 1
Views: 754
Reputation: 11542
You can:
1) Rewrite the entire project in C#
2) Reuse several components using either:
Upvotes: 6
Reputation: 47561
Well, plain P/Invoke is good to interface with C, but if you want to interop with some real C++ code, you would have to use something more sophisticated. With .NET, you can use C++/CLI. On Mono on and .NET you can use:
First option is less mature but seems to be more elegant.
Upvotes: 2