Inter-Appication Communication

V

Viper Venom

Dear All:

I am trying to write an application that consist 2 executables

1) Server.exe
2) Client.exe

I start the server.exe first and then start the two client exe by code and
kill both of the client when the server exit (This is already done)

The question is I want to pass an array of object from the server to the
client and the client will read the list dp some process. The client will
return a processed list back to the server.

Can someone suggest a way to do it in C#?

Thank you very much in advance for any suggestions.

Viper Venom
 
J

Jeffrey Tan[MSFT]

Hi Viper,

I think Allen has provided you the correct information about how to do
inter-application communication(More precision, inter-appdomain or
inter-process communication).

Beside remoting, you also can leverage System.Net namespace to use socket
to do the data transformation. But the difference is that socket is a low
level protocol, which know nothing about .Net object, so you have to
implement the serialization and de-serialization yourself.

At this point, I suggest you to take Allen's suggestion to use Remoting,
which is tailored for .Net, and is strong typed for .Net objects. It will
encapsulate some protocol to do the serialization/de-serialization itself,
so it is much easy for use.

I will also introduce some General information to you:

In Win32, there are many technical to implement inter-process
communication, such as WM_COPYDATA message, Memory Mapping File, Named Pipe
etc.., but they are all unmanaged technical and know nothing about .Net
managed classes.
In .Net, it introduces 2 technicals to access through AppDomain boundary:
.Net Remoting and Web Service. These 2 technicals have different usage,
remoting is more suitable for Client/Server structure application. Remoting
gives you the choice to use different protocol to transform data, such as
SOAP http or TCP.

After general information, I suggest you find some resource document or
book for Remoting to learn some detail information.

Thank you for your patience and cooperation. If you have any questions or
concerns, please feel free to post it in the group. I am standing by to be
of assistance.

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.
 
V

Viper Venom

Thank you very much for you detail reply.
I think I will go for the Remoting approach.

Viper Venom
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top