Click here to Skip to main content
15,945,119 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
i want to send data from a server to a device but device is in different network's subnet (both are able to connect to internet)is it possible for client to connect server which is in subbnetting.

Windows OS[10.20.30.40] --> -->> INTERNET -->>--> [13.14.15.16]ROUTER [192.168.1.1] --> Mobile-WIFI[192.168.1.5]

is there any way by which Windows can send data to Android device i mean can we pass the router NAT so that i could easily access mobile device some what like
Socket soc= new Socket("13.14.15.16/192.168.1.5",8080);

Windows OS[10.20.30.40] --> -->> INTERNET -->>--> [Hiding complexity] --> Mobile-WIFI [13.14.15.16/192.168.1.5]

it works fine when

Windows[192.168.1.5] -->--> Mobile-WIFI [192.168.1.9]

i have opened client server threads in both application( Windows server, mobile device) and have used TCP Sockets.
is it possible for client-server to send data bi-directional.
Posted
Updated 29-Jul-11 6:46am
v3
Comments
Richard MacCutchan 23-Jul-11 5:37am    
What happens when you try it?
01.mandar 28-Jul-11 3:03am    
actually it works fine when server and client are in local network.
problem begins when the client is in local network and server is on different network connected to internet.
i just want to bypass router to communicate tcp port on remote device
Richard MacCutchan 28-Jul-11 4:12am    
What problem? Unless you explain what is not working we cannot begin to guess what the problem might be. What do you mean "bypass the router"? If the network link goes through a router then you have no choice.

1 solution

This is not a programming question but one of connectivity. If your client device can connect via some network path to the server then your problem is solved, but if the pathway is blocked, possibly by a router then there is no way round it. A simple way of checking is by using the ping or tracert commands.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900