Contents Previous Page Next Page
IErrorLog::AddError

Logs an error (an EXCEPINFO structure) in the error log for a named property.

HRESULT AddError(

    LPCOLESTR  
pszPropName,            // Points to the name of the property involved with the error                        
                                                                                                                            
    LPEXCEPINFO   pException           // Points to the caller-initialized EXCEPINFO structure describing the error         
                                                                                                                            
   );                                                                                                                       
                                                                                                                            

Parameters

pszPropName

[in] The name of the property involved with the error. Cannot be NULL.

pExcepInfo

[in] The address of the caller-initialized EXCEPINFO structure that describes the error to log. Cannot be NULL.

Return Values

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 address in pszPropName or pExceptInfo is not valid (such as NULL). The caller must supply both.

Remarks

E_NOTIMPL is not a valid return code as the method is the only one in the entire interface.