Windows apps
Collapse the table of content
Expand the table of content
Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

GetThreadErrorMode function

Retrieves the error mode for the calling thread.

Syntax


DWORD GetThreadErrorMode(void);

Parameters

This function has no parameters.

Return value

The process error mode. This function returns one of the following values.

Return code/valueDescription
SEM_FAILCRITICALERRORS
0x0001

The system does not display the critical-error-handler message box. Instead, the system sends the error to the calling thread.

SEM_NOGPFAULTERRORBOX
0x0002

The system does not display the Windows Error Reporting dialog.

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 thread.

 

Remarks

A thread inherits the error mode of the process in which it is running. To change the error mode for the thread, use the SetThreadErrorMode function.

Requirements

Minimum supported client

Windows 7 [desktop apps only]

Minimum supported server

Windows Server 2008 R2 [desktop apps only]

Header

WinBase.h (include Windows.h)

Library

Kernel32.lib

DLL

Kernel32.dll

See also

GetErrorMode
SetThreadErrorMode

 

 

Show:
© 2017 Microsoft