Important:
This is retired content. This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This content may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.
A version of this page is also available for
4/8/2010

This method uses an EXCEPINFOstructure to log an error in the error log for a named property.

Syntax

HRESULT AddError(
  LPCOLESTR 
pszPropName,
  EXCEPINFO* 
pExcepInfo
);

Parameters

pszPropName

[in] Pointer to a string containing the name of the property involved with the error. This cannot be NULL.

pExcepInfo

[in] Pointer to the caller-initialized EXCEPINFOstructure that describes the error to log. This cannot be NULL.

Return Value

The following table shows the return values.

Value Description

S_OK

The error was logged successfully.

E_FAIL

There was a problem logging the error.

E_OUTOFMEMORY

There was not enough memory to log the error.

E_POINTER

The pointer in pszPropNameor pExcepInfois not valid (such as NULL). The caller must supply both.

Remarks

E_NOTIMPL is not a valid return code because this is the only method of the IErrorloginterface.

Requirements

Header oaidl.h, oaidl.idl
Library oleaut32.lib, uuid.lib
Windows Embedded CE Windows CE .NET 4.0 and later
Windows Mobile Windows Mobile Version 5.0 and later

See Also

Reference

IErrorlog
EXCEPINFO