hello
i am building a c/s application with a server resident on a different computer than those hosting the client.
to begin with, i successfully run both server and client are running on the *same* PC (IP address 192.168.0.8).
then i wanted to make things a bit more difficult, trying to make the communication up and running in my home intranet, i.e. the server is running on a different computer than the client: i.e. server at IP address 192.168.0.13, while the client is running on a different computer at 192.168.0.8 and this does not work: the client cannot listen to the server using IP address and port nr. of the server,

Qt code is as following:
This is for creating connection
Qt Code:
  1. tcpKeysFromServer = new QTcpServer(this);
  2. connect(tcpKeysFromServer, SIGNAL(newConnection()), this, SLOT(acceptConnectionFromKeysServer()));
To copy to clipboard, switch view to plain text mode 
this is to check client is listening (which is failing)
Qt Code:
  1. if (!tcpKeysFromServer->isListening() && ! tcpKeysFromServer -> listen (QHostAddress (m_ipAddressKeysServer), m_FromPortKeysServer) )
  2. {
  3. QString newLabelSvrName = tr("Unable to start KEYS server: check IP address!");
  4. ui.labelFromKeysServer->setText(newLabelSvrName);
  5. }
To copy to clipboard, switch view to plain text mode