QApplication::activeWindow() working incorrectly
Solved
Qt 6
-
Hello everyone!
QMessageBox::information(QApplication::activeWindow(),"Error", query.lastError().text(),QMessageBox::Ok);
When I use this construct, the QMESSAGEBOX returns an empty one with no message. The message is sent from another class that does not have widgets.
-
@iddqd-0 said in QApplication::activeWindow() working incorrectly:
QMESSAGEBOX returns an empty one with no message
What does this mean?
-
@Christian-Ehrlicher
instead of a window with an error message, I get just an empty window -
What Qt version do you use? Is this called from the main thread?
-
@Christian-Ehrlicher I'm using version 6.0.2. Yes, in main thread
-
Ok, fine. Can you create a minimal example to reproduce the problem? It looks like a QMessageBox in main() should also trigger your issue.
-
thanks for the help. Your tips helped solve the problem!