|Important||This document may not represent best practices for current development, links to downloads and other resources may no longer be valid. Current recommended version can be found here.|
Associates an error that is detected by run-time error checks (RTCs) with a type. Your error handler processes how to output errors of the specified type.
A number between zero and one less than the value returned by _RTC_NumErrors.
A value to assign to this errnum. For example, you might use _CRT_ERROR. If you are using _CrtDbgReport as your error handler, ErrType can only be one of the symbols defined in _CrtSetReportMode. If you have your own error handler (_RTC_SetErrorFunc), you can have as many ErrTypes as there are errnums.
An ErrType of _RTC_ERRTYPE_IGNORE has special meaning to _CrtSetReportMode; the error is ignored.
By default, all errors are set to ErrType = 1, which corresponds to _CRT_ERROR. For more information about the default error types such as _CRT_ERROR, see _CrtDbgReport.
Before you can call this function, you must first call one of the run-time error check initialization functions; see Using Run-Time Checks without the C Run-Time Library
Windows 95, Windows 98, Windows 98 Second Edition, Windows Millennium Edition, Windows Millennium Edition, Windows NT 4.0, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003
For more information, see Compatibility.
All versions of the C run-time libraries.
Not applicable. To call the standard C function, use PInvoke. For more information, see Platform Invoke Examples.