关于MessageBox显示的一个问题

zqqq1 2008-02-17 11:19:38
MessageBox(0, msgbuff,"WARNING",MB_YESNO|MB_ICONQUESTION|0x00200000L)

不知道有人这样使用过没有,就是最后多了一个0x00200000L的掩码,效果是该对话框总是显示在最上层,包括你按ctrl+alt+del进入锁定计算机状态,他也能显示出来,我想问两个问题:1、这个掩码是什么作用,有没有具体的解释。2、我想实现一个类似的模式对话框,即使在锁定计算机的情况下,也能显示出来,该怎么办。谢谢,100分
...全文
137 7 打赏 收藏 转发到动态 举报
写回复
用AI写文章
7 条回复
切换为时间正序
请发表友善的回复…
发表回复
zqqq1 2008-02-17
  • 打赏
  • 举报
回复
我知道,能不能做这么一个对话框,实现这个功能,你有qq吗,我的是81126700,加我
cnzdgs 2008-02-17
  • 打赏
  • 举报
回复
这个标志是MessageBox特有的,不能用与对话框。
zqqq1 2008-02-17
  • 打赏
  • 举报
回复
是这样呢,我主要是想在对话框上添加点Edit的控件,难道真的实现不了吗?
A_KIM 2008-02-17
  • 打赏
  • 举报
回复
#define MB_SERVICE_NOTIFICATION 0x00200000L

MB_SERVICE_NOTIFICATION

Windows NT/2000/XP: The caller is a service notifying the user of an event. The function displays a message box on the current active desktop, even if there is no user logged on to the computer.
Terminal Services: If the calling thread has an impersonation token, the function directs the message box to the session specified in the impersonation token.

If this flag is set, the hWnd parameter must be NULL. This is so the message box can appear on a desktop other than the desktop corresponding to the hWnd.

For more information on the changes between Microsoft Windows NT 3.51 and Windows NT 4.0, see Remarks.

zqqq1 2008-02-17
  • 打赏
  • 举报
回复
谢谢,那我能做一个类似的对话框吗
yxz_lp 2008-02-17
  • 打赏
  • 举报
回复

#ifdef _WIN32_WINNT
#if (_WIN32_WINNT >= 0x0400)
#define MB_SERVICE_NOTIFICATION 0x00200000L//就是这个
#else
#define MB_SERVICE_NOTIFICATION 0x00040000L
#endif
#define MB_SERVICE_NOTIFICATION_NT3X 0x00040000L
#endif

MB_SERVICE_NOTIFICATION
Windows NT: The caller is a service notifying the user of an event. The function displays a message box on the current active desktop, even if there is no user logged on to the computer.
cnzdgs 2008-02-17
  • 打赏
  • 举报
回复
我不会做。

15,978

社区成员

发帖
与我相关
我的任务
社区描述
VC/MFC 界面
社区管理员
  • 界面
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧