.NET Remoting

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • PulkitZery
    New Member
    • Jun 2007
    • 35

    .NET Remoting

    Hi I am stuck in a problem. I have developed an application, which has two buttons start and stop. All I want to do is to be able to push these Start and Stop buttons from a remote location (within the network). I know there is something available in .net library called .Net Remoting, but I dont know how to use it. Can anyone help me how can i do this. Thanks in advance.

    Pulkit Zery
  • TRScheel
    Recognized Expert Contributor
    • Apr 2007
    • 638

    #2
    Originally posted by PulkitZery
    Hi I am stuck in a problem. I have developed an application, which has two buttons start and stop. All I want to do is to be able to push these Start and Stop buttons from a remote location (within the network). I know there is something available in .net library called .Net Remoting, but I dont know how to use it. Can anyone help me how can i do this. Thanks in advance.

    Pulkit Zery

    From what I understand of System.Runtime. Remoting, it isn't what you want to use for this particular application. I would think you would need the application to accept incoming messages on a port and then do something based off the message. In this case, press start/stop. System.Net.Sock ets might be more what you are looking for, although I am sure you can use the other classes / namespaces within System.Net to do the same thing.

    Comment

    • PulkitZery
      New Member
      • Jun 2007
      • 35

      #3
      Originally posted by TRScheel
      I would think you would need the application to accept incoming messages on a port and then do something based off the message. In this case, press start/stop. System.Net.Sock ets might be more what you are looking for, although I am sure you can use the other classes / namespaces within System.Net to do the same thing.
      Thanks for your reply, what you suggested is exactly what i want to do. I have these following questions:
      How do you open a port and send messages?
      Do I need to run the main application as service or something?
      How do the client and the main application will communicate?

      If you can give me some code examples that would be excellent. Thanks in advance for your help.

      Pulkit Zery

      Comment

      • TRScheel
        Recognized Expert Contributor
        • Apr 2007
        • 638

        #4
        Originally posted by PulkitZery
        Thanks for your reply, what you suggested is exactly what i want to do. I have these following questions:
        How do you open a port and send messages?
        Do I need to run the main application as service or something?
        How do the client and the main application will communicate?

        If you can give me some code examples that would be excellent. Thanks in advance for your help.

        Pulkit Zery
        If I get some free time later today I can throw some sample code down for you, but I can describe the process fairly quickly.

        What you will do is have a program that actively listens for information on a port. Once it recieves information from that port, it deciphers it and attempts to make a decision about what to do with it. The program does not need to run as a service, but it will need to be allowed through the firewall. Communication is done over TCP or UDP, although you will probably use TCP.


        Also, here is the MSDN information about it, it should hopefully describe the process. I will check back on this thread in about an hour and a half or two, if you still have questions.

        MDSN - TCPClient

        MSDN - TCPListener

        Comment

        • TRScheel
          Recognized Expert Contributor
          • Apr 2007
          • 638

          #5
          Also, know that this is not the ONLY way you can go about it. I just prefer Sockets. I am sure you can do it with HTTPListener or other classes.

          Comment

          Working...