Send and receive messages to and from applications

  • Thread starter Thread starter Gerald Bader
  • Start date Start date
G

Gerald Bader

Hi all!

Is there a possibility to send messages from one application to another,
never minding if it is a .NET or a COM application?
The other application should "listen" whether there are Messages being sent
to it, and if so, respond itself with a message to the sender application.

Thanx for your hints.


Greetings

Gerald
 
Hello!

This assumes that the applications both are written in .NET

I need something that is independent of .NET - i.e. something that Windows
is offering (Message-Queues?).


Gerald
 
Gerald Bader said:
Is there a possibility to send messages from one application
to another, never minding if it is a .NET or a COM application?

Maybe you can set up communication using sockets, or (I have never worked
with it) MSMQ.
 
In the past I used a TCP socket and just had my apps listening on the
specified port. then it becomes easy to get the apps talking.

Bob
 
Hi!

Do you know where to get any sample code for TCP communication between
applications?
Or maybe some for UDP?


Gerald
 
It's the same as if you communicating with a separate machine. Program A
would need to listen on a given port on 127.0.0.1. Program B would then
just connect to that port on 127.0.0.1.

In case you don't know it, 127.0.0.1 is a reserved IP Address which
represents the local computer.

Richard Rosenheim
 
What kind of messages? The other posts sound good if you are sending data
that is particular to your application. But just wanted to add--if by
"messages" you mean standard Window messages, then the SendMessage API might
do the trick for you a little more easily.

Just in case.

Brian


--

Brian Schwartz
FishNet Components
http://www.fishnetcomponents.com
Building better tools for developers - Be part of it!
 

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

Back
Top