Vladimir_
24th September 2014, 16:04
Hello,
I wanted to do an action when an incoming connection to the server is established from a client.
i wrote this line :
connect(socket,SIGNAL(connected()), this, SLOT(connected()));
while "socket" is is a pointer to QTcpSocket :
socket = new QTcpSocket;
But the statement doesn't invoke te SLOT "connected()" .
but when I write the following code:
connect(socket,SIGNAL(disconnected()), this, SLOT(connected()));
The SLOT "connected()" will be called when the Client is exited.
The issue:
I need to invoke the SLOT when an incoming connection established from a client.
Thanks.
I wanted to do an action when an incoming connection to the server is established from a client.
i wrote this line :
connect(socket,SIGNAL(connected()), this, SLOT(connected()));
while "socket" is is a pointer to QTcpSocket :
socket = new QTcpSocket;
But the statement doesn't invoke te SLOT "connected()" .
but when I write the following code:
connect(socket,SIGNAL(disconnected()), this, SLOT(connected()));
The SLOT "connected()" will be called when the Client is exited.
The issue:
I need to invoke the SLOT when an incoming connection established from a client.
Thanks.