Skip to content

Latest commit

 

History

History
61 lines (42 loc) · 2.35 KB

rtc-seterrortype.md

File metadata and controls

61 lines (42 loc) · 2.35 KB
description title ms.date api_name api_location api_type topic_type f1_keywords helpviewer_keywords ms.assetid
Learn more about: _RTC_SetErrorType
_RTC_SetErrorType
11/04/2016
_RTC_SetErrorType
msvcrt.dll
msvcr80.dll
msvcr90.dll
msvcr100.dll
msvcr100_clr0400.dll
msvcr110.dll
msvcr110_clr0400.dll
msvcr120.dll
msvcr120_clr0400.dll
ucrtbase.dll
DLLExport
apiref
RTC_SetErrorType
_RTC_SetErrorType
run-time errors
RTC_SetErrorType function
_RTC_SetErrorType function
f5f99be7-d357-4b11-b8f5-ddd3428f2b06

_RTC_SetErrorType

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.

Syntax

int _RTC_SetErrorType(
   _RTC_ErrorNumber errnum,
   int ErrType
);

Parameters

errnum
A number between zero and one less than the value returned by _RTC_NumErrors.

ErrType
A value to assign to this errnum. For example, you might use _CRT_ERROR. If you're 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 ErrType values as there are errnum values.

An ErrType of _RTC_ERRTYPE_IGNORE has special meaning to _CrtSetReportMode; the error is ignored.

Return value

The previous value for the error type replaced by ErrType.

Remarks

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 runtime checks without the C runtime library

Requirements

Routine Required header
_RTC_SetErrorType <rtcapi.h>

For more information, see Compatibility.

Libraries

All versions of the C run-time libraries.

See also

_RTC_GetErrDesc
Runtime error checking