we have two applications, a native C++ application and a managed C#/WPF UI that creates input for, executes & reads output generated by the native application. Currently, communication between the two is done with XML & plain txt files.
However, the amount of output data is quite large & we are looking for a better approach to this. A solution that uses something like Memorystream would be ideal because it would easy to switch the output generation from a filestream to a memorystream.
However, how does one bridge the gap between managed & unmanaged? What is the most efficient way to do this?
Note: Many of the questions related to this are about a function call from a managed to an unmaged dll. These are two separate applications running independently. The UI spawns the native application, this is the only link between the two.
Thanks
You could try a named pipe
http://www.switchonthecode.com/tutorials/interprocess-communication-using-named-pipes-in-csharp