其他分享
首页 > 其他分享> > QT中的消息对话框

QT中的消息对话框

作者:互联网

QMessageBox

 

 

  //错误对话框
        //QMessageBox::critical(this,"critical","错误");

        //信息对话框
        //QMessageBox::information(this,"critical","信息对话框");
        //警告对话框
        //QMessageBox::warning(this,"critical","警告对话框");
        //提问对话框
       if(QMessageBox::Close==QMessageBox::question(this,"ques","提问对话框",QMessageBox::Open|QMessageBox::Close|\
                              QMessageBox::Save|QMessageBox::Discard|QMessageBox::YesToAll,\
                              QMessageBox::Close))
       {
           qDebug()<<"提问对话框关闭了";

       };

标签:QT,对话框,critical,消息,QMessageBox,Close,警告,提问
来源: https://www.cnblogs.com/qq376142178/p/15334148.html