Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
How can we open 2 qwidget simulatenously
Himanshupradhan last edited by
i have taken a tcp/ip server client code from Qtexample[Fortune], and a analog clock example, firstly i run a tcp server and client program, now in tcp server program , in file server.cpp, in function send fortune, i am calling analog clock code[clock.show()], so it comes just for .1 second and disappear, i want to show this clock also, means that clock stay there.
miroslav last edited by
A common mistake is to create the widget variable on the stack, instead of using new. Showing multiple top-level widgets is not a problem in Qt.
fluca1978 last edited by
Can you post the code that opens/shows the clock? I suspect that either you are allocating it on the stack, as miroslav suggested, or you are opening it thru a widget that is going to be deleted.