Showmessage('保存成功');
messagedlg('确定要保存记录吗?',mtconfirmation,[mbyes,mbno],0)=mryes;以上两种对话框,有时会隐在表单之后,导致无法按“确定”,无法进行下一步的操作。
用ALT+TAB可以调出对话框。只是有时,而不是每一次。
请各位大侠,分析一下原因。

解决方案 »

  1.   

    你是不是在MDI窗体内这样显示呢?这是WINDOWS固有问题。
      

  2.   

    Application.MessageBoxMessageBox(最前的窗體的handle
      

  3.   

    Application.MessageBox('', '' , MB_YESNO + MB_ICONQUESTION + MB_TOPMOST) ;也许能榜上你,showmessage的问题我都是通过切换菜单栏任务来使他再次显示在前面。
      

  4.   

    在WINDOWS程序中没遇过.不过在网页上调用有遇过.学习一下.
      

  5.   


    用api函数MessageBox
    int MessageBox(
        HWND hWnd, // 这个就是窗体句柄,box会在这个句柄的窗体前面
        LPCTSTR lpText, // address of text in message box
        LPCTSTR lpCaption, // address of title of message box  
        UINT uType  // style of message box
       );
      

  6.   

    没遇到过,只用一种messagedlg不行吗?
      

  7.   

     if MessageBox(Application.Handle,^M' 是否确认退出?'^M,'系统提示',MB_ICONQUESTION+MB_OKCANCEL)=IDOK then
      

  8.   


    Application.MessageBox or Messagebox or messagedlg都可以1.Application.MessageBox('', '' , MB_YESNO + MB_ICONQUESTION + MB_TOPMOST) ; 
    2.if MessageBox(Application.Handle,^M' 是否确认退出?'^M,'系统提示',MB_ICONQUESTION+MB_OKCANCEL)=IDOK then 
    3.if MessageDlg('是否確定刪除此記錄?',mtwarning,[mbyes,mbno],0)=mryes then