Error Message Format for Windows SharePoint Services

Methods for Microsoft Windows SharePoint Services return error messages using the following syntax:

<Results>
  <Result ID="0,method-name" Code="HRESULT code">
    <ErrorText>Description of failure</ErrorText>
  </Result>
</Results>

The ID attribute displays the name of the method that generated the error, preceded by its sequence number. The Code attribute contains the text representation of a 32-bit signed decimal integer, to be interpreted as an HRESULT. For example:

<Results>
  <Result ID="0,REORDERFIELDS" Code="-2147467259">
    <ErrorText>Fields have been added or removed since you began this editing session. Please refresh your view and try
      again.
    </ErrorText>
  </Result>
</Results>

In the preceding example, the error number -2147467259 (0x80004005 in hexadecimal) identifies the error E_FAIL.

Note  The language of the error text is based upon the language setting for the server, not the client language setting.