int MessageBox(
  HWND hWnd,          // handle of owner window
  LPCTSTR lpText,     // address of text in message box
  LPCTSTR lpCaption,  // address of title of message box
  UINT uType          // style of message box
);

在uType参数中设置MB_SYSTEMMODAL就能让MessageBox在最上面;

 示例:

MessageBox(_T(" 程序错误!"),_T("Warning"),MB_SYSTEMMODAL|MB_ICONEXCLAMATION|MB_OK);

相关文章:

  • 2021-08-29
  • 2021-08-12
  • 2022-12-23
  • 2021-04-21
  • 2021-07-09
  • 2021-11-23
  • 2021-06-26
猜你喜欢
  • 2022-12-23
  • 2021-10-13
  • 2022-12-23
  • 2022-12-23
  • 2021-05-19
  • 2022-02-15
  • 2022-12-23
相关资源
相似解决方案