Important: Please read the Qt Code of Conduct -

QMessageBox on console/background application

  • Hi all,

    I'm developing a mobile application which runs in background, so without any UI or dialog/window. But I would like to show a QMessage when an error occurs. It is possible?

    I don't know how because the QMessage constructor has a "QWidget* parent" parameter and I haven't anyone QWidget.

    Thanks a lot,

  • I suppose you are talkin about QMessageBox. Actually this class has a constructor with @QWidget *parent=0@ which means that you do not need to pass a QWidget as parent.

    If you do not it will take the default value 0 (as defnied above) so it has no parent.

Log in to reply