用ExitWindowsEx(EWX_SHUTDOWN,0)和ExitWindowsEx(EWX_POWEROFF,0)都能关机,它们有什么区别吗?
或者说哪个更好一些,百度和谷歌上没找着,CSDN上也没发现,请教各位大牛了,谢谢!
或者说哪个更好一些,百度和谷歌上没找着,CSDN上也没发现,请教各位大牛了,谢谢!
解决方案 »
- 在WIN32下使用webbrowser 运行报错,有代码,高手帮忙看下啊。
- 急!TransparentImage函数在VC中不能用??
- 动态修改菜单文本问题,SetMenuItemInfo成功了,但是文本显示不出来,DrawMennuBar也调用了,不解???
- 如何在静态文本控件上设置左右键同时单击事件???
- 如何在Multiple的ListBox中删除选中的多个项目?有没有简捷的办法?
- 如何打印CVIEW中的控件
- 请问我的应用程序属于什么结构,并评论我的应用程序结构是否合理?
- ★大家都把自己【最拿手最新】的作品贴出来吧!回帖都有分!我先贴上我自己的!D
- 基类cobject
- 怪异的屏幕录制程序
- 哪位高手大虾能给我提供一个基于TDI层和NDIS层的个人防火墙源代码,急用呀,那位大虾帮帮忙,谢谢呀!!
- ctabctrl的msctls_updown32有办法让他一直显示么?
0x00000008
Shuts down the system and turns off the power. The system must support the power-off feature. The calling process must have the SE_SHUTDOWN_NAME privilege. For more information, see the following Res section.
---------------------------------
EWX_SHUTDOWN
0x00000001
Shuts down the system to a point at which it is safe to turn off the power. All file buffers have been flushed to disk, and all running processes have stopped. The calling process must have the SE_SHUTDOWN_NAME privilege. For more information, see the following Res section.Specifying this flag will not turn off the power even if the system supports the power-off feature. You must specify EWX_POWEROFF to do this.Windows XP SP1: If the system supports the power-off feature, specifying this flag turns off the power.
发现在开始菜单里用正常操作关机时调用ExitWindowsEx时,第一个参数是9,
也就里是等于
EWX_SHUTDOWN + EWX_POWEROFF
因为第一个参数只是一个,不是几个参数吧,因为文档说了,只能选择之一啊!!“The shutdown type. This parameter must include one of the following values. ”