void LogError(uErr, lpvInfo) | |||||
UINT uErr; | /* error type | */ | |||
void FAR* lpvInfo; | /* address of error information | */ |
The LogError function identifies the most recent system error. An application's interrupt callback function typically calls LogError to return error information to the user.
uErr
Specifies the type of error that occurred. The lpvInfo parameter may point to more information about the error, depending on the value of uErr. This parameter may be one or more of the following values:
Value | Meaning |
ERR_ALLOCRES | AllocResource failed. |
ERR_BADINDEX | Bad index to GetClassLong, GetClassWord, GetWindowLong, GetWindowWord, SetClassLong, SetClassWord, SetWindowLong, or SetWindowWord. |
ERR_BYTE | Invalid 8-bit parameter. |
ERR_CREATEDC | CreateCompatibleDC, CreateDC, or CreateIC failed. |
ERR_CREATEDLG | Could not create dialog box because LoadMenu failed. |
ERR_CREATEDLG2 | Could not create dialog box because CreateWindow failed. |
ERR_CREATEMENU | Could not create menu. |
ERR_CREATEMETA | CreateMetaFile failed. |
ERR_CREATEWND | Could not create window because the class was not found. |
ERR_DCBUSY | Device context (DC) cache is full. |
ERR_DELOBJSELECTED | Program is trying to delete a bitmap that is selected into the DC. |
ERR_DWORD | Invalid 32-bit parameter. |
ERR_GALLOC | GlobalAlloc failed. |
ERR_GLOCK | GlobalLock failed. |
ERR_GREALLOC | GlobalReAlloc failed. |
ERR_LALLOC | LocalAlloc failed. |
ERR_LLOCK | LocalLock failed. |
ERR_LOADMENU | LoadMenu failed. |
ERR_LOADMODULE | LoadModule failed. |
ERR_LOADSTR | LoadString failed. |
ERR_LOCKRES | LockResource failed. |
ERR_LREALLOC | LocalReAlloc failed. |
ERR_NESTEDBEGINPAINT | Program contains nested BeginPaint calls. |
ERR_REGISTERCLASS | RegisterClass failed because the class is already registered. |
ERR_SELBITMAP | Program is trying to select a bitmap that is already selected. |
ERR_SIZE_MASK | Identifies which 2 bits of uErr specify the size of the invalid parameter. |
ERR_STRUCEXTRA | Program is using unallocated space. |
ERR_WARNING | A non-fatal error occurred. |
ERR_WORD | Invalid 16-bit parameter. |
lpvInfo
Points to more information about the error. The value of lpvInfo depends on the value of uErr. If the value of (uErr & ERR_SIZE_MASK) is 0, lpvInfo is undefined. Currently, no uErr code has defined meanings for lpvInfo.
This function does not return a value.
The errors identified by LogError may be trapped by the callback function that NotifyRegister installs.
Error values whose low 12 bits are less than 0x07FF are reserved for use by Windows.