I am using SimpleTcpServer in a Windows Forms Application and when I use an IPAddress 10.10.5.27 Port 8080 gives Exception System.Net.Sockets.SocketException
The Form starts with the following statement below:
private void Form1_Load(object sender, EventArgs e)
{
this.Hide();
this.WindowState = FormWindowState.Minimized;
server = new SimpleTcpServer
{
//server.Delimiter = 0x13;
StringEncoder = Encoding.UTF8
};
server.DataReceived += Server_DataReceived;
IniciaServico();
}
After the Form gives a Load executes the StartService giving exception on the server.Start (ip, 8080) line;
private void IniciaServico()
{
IPAddress ip = IPAddress.Parse("10.10.5.27");
server.Start(ip, 8080);
Habilita(false);
txtStatus.Text += "Serviço ativo...";
}
Note to use Ip 127.0.0.1 on port 8910 works, but I need to communicate with this Ip 10.10.5.27