Hi all, I was looking at the API, and Ive tried to determine this:
On a given port, check if it's available or already some application listens to it.
Thanks,
ray.
Hi all, I was looking at the API, and Ive tried to determine this:
On a given port, check if it's available or already some application listens to it.
Thanks,
ray.
If you are binding on a specific port, then there is probably something wrong with your Android code; most likely, you should only make outbound connections. If you need to communicate to some other Android device, consider having both devices connect to a common web service that bridges the connection. Using a web service as an intermediary decouples the connection between the devices and also avoids common problems where routers or firewalls block incoming connections.
The Ive found a way to check it.
By using SocketConnecton, and open it on the request port, if it's not available an IO Exception will be thrown.