Send data between two applications?

  • Thread starter Thread starter Cross
  • Start date Start date
C

Cross

What is the easiest way to send data from one vb.net application to another
(I know I could write to the harddrive or registry, but that does not feel
like a good solution). Someone must have don this before an ave a short and
good example. I have heard of something calle memory mapped file, that might
be a solution, but I can't fine anything abot it.
 
What is the easiest way to send data from one vb.net application to another
(I know I could write to the harddrive or registry, but that does not feel
like a good solution). Someone must have don this before an ave a short and
good example. I have heard of something calle memory mapped file, that might
be a solution, but I can't fine anything abot it.

There are lots of ways to do this, depending on the type and amount of
data your trying to transfer :)

For simple, string data - you might look into using WM_COPYDATA. If you
need something more complex, you can use remoting or WCF to transfer the
data. You could even just use regular old sockets...

Can you provide a little more information about the scenario? It might
make giving you a solution a little easier :)
 
The senario is, it will be pretty small set of thata that I want to send.
Like a string or o byte of array. Note (I forgot to mension cause I thioght
it was obvious) the both applications are running on the same PC.

Let me know if you nead any more specific details.
 
Isn't that an overkill sulotion? What I know, named pipes is a method for
transfering data from one computer to another, but that is not what I want
to do, the both applications are running on the same PC.
 
Thanks Herfried

Cor

Herfried K. Wagner said:
Cor,




Note that there is even a managed wrapper around pipes (anonymous and
named) available in .NET 3.5: 'System.IO.Pipes'.
 
Isn't that an overkill sulotion? What I know, named pipes is a method
for transfering data from one computer to another, but that is not
what I want to do, the both applications are running on the same PC.

Just use WCF or Remoting, it safe and easy to use.
 
The senario is, it will be pretty small set of thata that I want to send.
Like a string or o byte of array. Note (I forgot to mension cause I thioght
it was obvious) the both applications are running on the same PC.

Let me know if you nead any more specific details.

Small set of data, same machine. Looks like string data, or something
that can be converted to string data (using Convert.ToBase64String),
then I would look at using WM_COPYDATA...

Of course if your using 3.5, then you might look at System.IO.Pipes.
 
Back
Top