Share via


RpcExceptionCode

The RpcExceptionCode function retrieves a code that identifies the type of exception that occurred.

unsigned long RpcExceptionCode(void);

Parameters

This function has no parameters.

Return Value

Possible return values include the set of error codes returned by the RPC functions with the prefixes "RPC_S_" and "RPC_X" and the set of exceptions returned by the Windows operating system.

Note  For a list of valid error codes, see RPC Return Values.

Remarks

The RpcExceptionCode function can only be called from within the expression and exception statements of an RpcTryExcept exception handler.

Requirements

Client Requires Windows Vista, Windows XP, Windows 2000 Professional, Windows NT Workstation, Windows Me, Windows 98, or Windows 95.
Server Requires Windows Server "Longhorn", Windows Server 2003, Windows 2000 Server, or Windows NT Server.
Header

Declared in Rpc.h.

Library

Use Rpcrt4.lib.

DLL Requires Rpcrt4.dll.

See Also

Exception Handling
RpcExcept
RpcFinally