Socket s = null; IPEndPoint ipe = new IPEndPoint(IPAddress.Parse("192.168.1.3"), 999); Socket tempSocket = new Socket(ipe.AddressFamily, SocketType.Stream, ProtocolType.Tcp); tempSocket.Connect(ipe);