Setting the server port[solved]
-
hello every one..
My application needs the communication between server and client application ,
but every time when i launch server side program the port get changes.
can anybody tell how to set the port -
Hi,
If you are using QTcpServer, set the port when you call listen.
Hope it helps
-
@SGaist:
thanks
yes,we are using TcpServer. If you provide the code snippet it would be of great help.. -
Look at the "docs":http://qt-project.org/doc/qt-4.8/qtcpserver.html#listen.
-
And examples: "network":http://qt-project.org/doc/qt-5.0/qtnetwork/examples-network.html
-
problem solved.. thanks everyone :) :)
-
You're welcome :)
Please, update the thread title to solved so other people on the forum knows when searching
-
tcpServer->listen(QHostAddress::Any,portnumber);
-
[quote author="preeth" date="1363748622"]tcpServer->listen(QHostAddress::Any,portnumber);[/quote]
SGaist mean edit a title of first post and add to it "[solved]" :) -
edited :)