I have some .NET C# code that I want to execute through a compiled (unmanaged) C++ program.
Currently what I have done is to put the former into a separate .exe file, which I execute from the C++ program. (The C++ program executes the .exe file, passing in the proper arguments, and captures its output into a variable.)
This works. However, executing a separate .exe file introduces some overhead, and the overhead is noticeable - one notices a half a second gap or so while the .exe program runs and finishes.
Question: Are there any better ways to do such integration? Something that would be faster than executing an .exe.
I'm on Windows XP running Visual Studio 2010.