Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Remove ? button QMessageBox
Forum Updated to NodeBB v4.3 + New Features

Remove ? button QMessageBox

Scheduled Pinned Locked Moved General and Desktop
4 Posts 3 Posters 3.1k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M Offline
    M Offline
    Misty River
    wrote on last edited by
    #1

    Hello,

    I try to create a messagebox without the help button but I can't get it to go away...

    mybox = new QMessageBox(QMessageBox::Information, "title", "messagebox", QMessageBox::Ok, this, Qt::WindowCloseButtonHint);

    With QDialog I set the window flags to closebuttonhint and it's enough to get rid of the help button but it doesn't work with message boxes...

    RatzzR 1 Reply Last reply
    0
    • M Misty River

      Hello,

      I try to create a messagebox without the help button but I can't get it to go away...

      mybox = new QMessageBox(QMessageBox::Information, "title", "messagebox", QMessageBox::Ok, this, Qt::WindowCloseButtonHint);

      With QDialog I set the window flags to closebuttonhint and it's enough to get rid of the help button but it doesn't work with message boxes...

      RatzzR Offline
      RatzzR Offline
      Ratzz
      wrote on last edited by
      #2

      Hi,
      you can try this.

      QMessageBox *msgBox = new QMessageBox(QMessageBox::Information,"title","messagebox " , QMessageBox::Ok,this);
      msgBox->exec();

      --Alles ist gut.

      1 Reply Last reply
      0
      • D Offline
        D Offline
        Devopia
        wrote on last edited by
        #3

        hi

        try this, but rid of all buttons, icon and system menu...

        QMessageBox msg(QMessageBox::Information, "title", "messagebox", QMessageBox::Ok, this);
        msg.setWindowFlags(Qt::Dialog | Qt::WindowTitleHint | Qt::CustomizeWindowHint);
        msg.exec();
        
        1 Reply Last reply
        0
        • M Offline
          M Offline
          Misty River
          wrote on last edited by
          #4

          Neither works.... It works if you use the static function but then it uses exec() which is not what I want because it blocks application flow.. I need to be able to call show() instead...

          1 Reply Last reply
          0

          • Login

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • Users
          • Groups
          • Search
          • Get Qt Extensions
          • Unsolved