|
In .NET we have the System.IO namespace providing convenient classes for Sockects and Pipes which ay be used for interprocess communication. How can one implement this in oldskool VC6?
My requirements are as follows.
I am writing a plugin for some legacy software for which there is a SDK which I can only get to compile with VC++6.0 compiler. I want to interface this code with both .NET and JAVA. I was thinking of implementing either a Socket server or Namedpipe in C# to act a a bridge between the VC6 code and .NET/JAVA. Requests from VC6 would be in the form of byte[] arrays and the C# bridge would interpret these requests, route them and eventually reply to the VC6 code which is awaiting a response.
In summary I would like examples of the following in VC++6:
- Use of threads
- Socket/Pipes (or any other interproc comms method)
- Invoking a process (other than a shell call to an executable)
BTW non-MFC is required
Any suggestions would be great.
Best, Y
|
|
|
|
|
|
Thanks Superman,
Exactly what I wanted. Whenever I search msdn I seem to find it have to get relevant results. my only realy experience it with .NET/JAVA and therefore when looking I'm a little non-plussed when it comes to C++/MFC and what is possible.
Great
|
|
|
|
|
If you want to simplify things, rather than use the sockets or named pipes, you might consider these two other options for the .NET part:
1) C++/CLI to generate a bridge DLL from the C# code that loads and runs the VC 6 DLL.
2) PInvoke from C# to load and run the VC 6 DLL.
For the Java part, you might do the process execution or use one of the Java - .NET bridges that exist out there.
Just some other suggestions to consider.
|
|
|
|