Communicating between 2 applications on localhost  
Author Message
Deldy





PostPosted: .NET Framework Networking and Communication, Communicating between 2 applications on localhost Top

Well, lets say I have two applications, on my local computer, and I want to comunicate between them. Is remoting then the best thing to use, or is there another technologi I should use instead

Another problem there is releated to this is, if I have an application, where I want to only be able to have one instance of the application to run at a time, then how do I for exsample ask it to open a new file, based on what file the user clicked on in explorer (For exsample a notepad, with tabs or something)


Is remoting really the things that should be used to this, or is there another more recommended way for .NET applications


.NET Development23  
 
 
RizwanSharp





PostPosted: .NET Framework Networking and Communication, Communicating between 2 applications on localhost Top

If both applications are on same computer or on the same intranet then Romiting is recomended way do it, its Similicity and Isolation with business logic of your application, You just need to Host a remotable object in one application and call its function from the other so it'll be like its a single application calling functions in different part of it. So Its very simple and recomended implementation when you are working in Intra net Domain!

There is also a soluion Webservice! But its not good in your Scenerio, Webservices behave slower than the remoting!

In last Sockets..... But wil make your logic complexer but will be efficient than using Remoting.

My personal Recomendation is to use Remoting!

About Single instance application See www.codeproject.com , there are many implementations of what your are going to do!

Best Regards,



 
 
Jorg Jooss - MSFT





PostPosted: .NET Framework Networking and Communication, Communicating between 2 applications on localhost Top

Assuming .NET 3.0 is a feasible platform, I would strongly consider using Windows Communication Foundation and its net.pipe binding for local communication.


 
 
Mike Flasko





PostPosted: .NET Framework Networking and Communication, Communicating between 2 applications on localhost Top

All the suggestions made a good ones. It really comes down to what your requirements are. For example, if you are doing a simple file transfer then the above solutions might be more overhead than needed. If you can detail the requirements than I bet the folks on this thread can lead you the right direction