I was kind of surprised when I saw this that the guy knew the break down of the hex error codes. Maybe I am showing my inexperience, but does someone know a MSDN or Technet document that breaks down the entire formation of hex error codes in Windows? I would be interested to read it.
There are Windows system specific error codes which are documented here, but other API's and technologies will have their own lists of result codes.
The one in your example is an ADSI error code.
That error code specifically is a Win32 related error thrown by ADSI.
Basically, you search for a specific code if you run across one or look for the API references for the technologies that you are working with and go to MSDN to get their error code reference.
In the case of the example, the fact that the ADSI code starts with 0x8007 means it's a Windows System (Win32) error. The last 4 digits of the ADSI hex error code translate into the specific dword value of the Win32 error code.
Here's a list of system return codes on MSDN. It's rather extensive (15999 codes!), so get your coffee ready. ;-)
Additionally, you can convert the number to decimal, and then call the