SetErrorMode Function
Controls whether the system will handle the specified types of serious errors or whether the process will handle them.
系统或者进程是否处理指定类型错误
UINT WINAPI SetErrorMode(
__in UINT uMode
);
Parameters
- uMode
-
The process error mode. This parameter can be one or more of the following values.
-
进程错误模式,参数值可以是以下一个或多个值
Value
Meaning0
Use the system default, which is to display all error dialog boxes.使用系统用默认有的全球错误对话框显示
-
SEM_FAILCRITICALERRORS
0x0001 -
The system does not display the critical-error-handler message box. Instead, the system sends the error to the calling process.
系统不显示critical-error-handler 消息对话框,只是把错误信息发到调用进程
-
-
SEM_NOALIGNMENTFAULTEXCEPT
-
0x0004
-
The system automatically fixes memory alignment faults and makes them invisible to the application. It does this for the calling process and any descendant processes. This feature is only supported by certain processor architectures. For more information, see the Remarks section.
After this value is set for a process, subsequent attempts to clear the value are ignored.
-
系统自动处理内存队列中的错误,对应用程序来说是不可见的。
SEM_NOGPFAULTERRORBOX
-
0x0002
The system does not display the general-protection-fault message box. This flag should only be set by debugging applications that handle general protection (GP) faults themselves with an exception handler.
-
系统不显示 一般默认的消息对话框。
-
SEM_NOOPENFILEERRORBOX
-
0x8000
The system does not display a message box when it fails to find a file. Instead, the error is returned to the calling process.