delphi里有显示“确定”和“取消”这两种选择按钮的对话框吗?就像web程序里的confirm对话框啊

解决方案 »

  1.   

    MessageBox(handle, 'hellE', 'Confirm', MB_OKCANCEL);
      

  2.   

    MessageBox('This should be on top.', 'Look', [smbOK]);
      

  3.   

    to meiqingsong(阿飛)
    返回值是boolean型吗?
    能给我举个例子吗?解决马上给分!!
      

  4.   

    procedure TForm1.Button1Click(Sender: TObject);begin
      if MessageDlg('Welcome to my Delphi application.  Exit now?',
        mtConfirmation, [mbYes, mbNo], 0, mbYes) = mrYes then
      begin
        MessageDlg('Exiting the Delphi application.', mtInformation,
          [mbOk], 0, mbOk);
        Close;
      end;end;
      

  5.   

    呵呵,很多的。application.messagebox()就可以
      

  6.   

    procedure TForm1.ExitSystemClick(Sender: TObject);begin
      if MessageDlg( 确定退出本系统?',
        mtConfirmation, [mbYes, mbNo], 0, mbYes) = mrYes then
         Application.terminate;
      end;
    end;-----------------------------------------------------------------------
    proceudre ExitSystem(Sender: TOBject)
    begin
      if MessageBox(handle, '确定退出本系统?', '系统提示', MB_OKCANCEL) = mrOK then
        Application.terminate;
    end;
      //  Messagebox  返回是的integer型, 看DELPHI的HELP
        
      

  7.   

    application.messagebox(自己选择参数)
    返回值为boolean型
    程序楼上的都写了。
      

  8.   

    MessageBox(handle, 'hellE', 'Confirm', MB_OKCANCEL);
    MessageBox(handle, 'hellE', 'Confirm', MB_YESNOCANCEL);
    你直接用delphi的ide可以自动生成下拉菜单,慢慢选择啦