I have a server object as
TcpChannel tcp = new TcpChannel(1234);
ChannelServices.RegisterChannel(tcp, false);
string s = ConfigurationManager.AppSettings["remote"];
RemotingConfiguration.RegisterWellKnownServiceType(typeof(TestRemoting.InitialClass1), "TestRemoting", WellKnownObjectMode.Singleton);
Console.WriteLine("Server is running on 1234 channel...");
Console.WriteLine("Press Enter to Stop");
Console.ReadLine();
and I am accessing that object in mu client form like
InitialClass1 Icls = (InitialClass1)Activator.GetObject(typeof(InitialClass1), "tcp://localhost:1234//TestRemoting");
Now I am keeping my remote object in another computer. How can I access my server object from that computer. If I access the server object from my (local) computer, I will use
"tcp://localhost:1234//TestRemoting"
I am using localhost here, because my server object and my client is same. So If those two are different, How can I access the server object. I tried with my another computer IP as
tcp://200.100.0.52:1234//TestRemoting
that time I am getting an exception as
A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond 200.100.0.52:1234
The message means most of the time that the client cannot find the service. You can use the following steps to determine where the connection fails:
The step on which it fails gives an indication of why it is failing.